X-Git-Url: http://research.m1stereo.tv/gitweb?a=blobdiff_plain;f=src%2Fmodules%2Favformat%2Fproducer_avformat.c;h=b5f7f62e816d4ff1c83e07af009c94bc546859d6;hb=5a3b9710ee1fbc6f079465d7a94afb0b17a6e9a2;hp=6ebd5683a63de1cc609d07329631fb72b12926b8;hpb=0d368e962076c3b96040b86cd5d87a1bbfe0a594;p=melted diff --git a/src/modules/avformat/producer_avformat.c b/src/modules/avformat/producer_avformat.c index 6ebd568..b5f7f62 100644 --- a/src/modules/avformat/producer_avformat.c +++ b/src/modules/avformat/producer_avformat.c @@ -232,7 +232,7 @@ static int producer_open( mlt_producer this, char *file ) { mrl[0] = 0; char *name = strdup( ++mrl ); - char *value = strchr( name, '=' ); + char *value = strchr( name, ':' ); if ( value ) { value[0] = 0; @@ -379,7 +379,7 @@ static int producer_get_image( mlt_frame frame, uint8_t **buffer, mlt_image_form mlt_position expected = mlt_properties_get_position( properties, "video_expected" ); // Calculate the real time code - double real_timecode = producer_time_of_frame( this, position ) + mlt_properties_get_double( properties, "_v_pts_offset" ); + double real_timecode = producer_time_of_frame( this, position ); // Get the video stream AVStream *stream = context->streams[ index ]; @@ -492,14 +492,7 @@ static int producer_get_image( mlt_frame frame, uint8_t **buffer, mlt_image_form if ( got_picture ) { if ( pkt.pts != AV_NOPTS_VALUE && pkt.pts != 0 ) - { - if ( current_time == 0 ) - { - mlt_properties_set_double( properties, "_v_pts_offset", ( double )( pkt.pts / 1000000 ) ); - real_timecode += pkt.pts / 1000000; - } current_time = ( double )pkt.pts / 1000000.0; - } else current_time = real_timecode;