From: Dan Dennedy Date: Mon, 29 Aug 2011 03:10:04 +0000 (-0700) Subject: Copy VITC to frame meta property. X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=14119031ede6619dfe78ac4b5909c4452de10bbe;p=mlt Copy VITC to frame meta property. Can be burned in with data_show filter. Perhaps this can be stored on the producer property using key frames for discontinuities. Then, it can be retrieved and supplied to some new filter that would put the meta.attr.vitc.markup property on frames. --- diff --git a/src/modules/decklink/producer_decklink.cpp b/src/modules/decklink/producer_decklink.cpp index fbef7f7d..58e9c9a2 100644 --- a/src/modules/decklink/producer_decklink.cpp +++ b/src/modules/decklink/producer_decklink.cpp @@ -352,6 +352,22 @@ public: mlt_frame_close( frame ); frame = 0; } + + // Get timecode + IDeckLinkTimecode* timecode = 0; + if ( video->GetTimecode( bmdTimecodeVITC, &timecode ) == S_OK && timecode ) + { + const char* timecodeString = 0; + + if ( timecode->GetString( &timecodeString ) == S_OK ) + { + mlt_properties_set( MLT_FRAME_PROPERTIES( frame ), "meta.attr.vitc.markup", timecodeString ); + mlt_log_verbose( getProducer(), "timecode %s\n", timecodeString ); + } + if ( timecodeString ) + free( (void*) timecodeString ); + timecode->Release(); + } } else {