X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fmodules%2Fcore%2Fproducer_consumer.c;h=d777e949bb756f7c4b70f94683e721c32314ccb4;hb=e273c00863839656468d7273759fe8d5daddac23;hp=794843d0c8cc9e4526262e3d7f239f995098b5eb;hpb=96c605eaac7272e3b37a0df718f9196fd5acbe96;p=mlt diff --git a/src/modules/core/producer_consumer.c b/src/modules/core/producer_consumer.c index 794843d0..d777e949 100644 --- a/src/modules/core/producer_consumer.c +++ b/src/modules/core/producer_consumer.c @@ -168,8 +168,8 @@ static int get_frame( mlt_producer this, mlt_frame_ptr frame, int index ) if ( mlt_producer_get_speed( this ) != 0 ) actual_position *= mlt_producer_get_speed( this ); mlt_position need_first = floor( actual_position ); - mlt_producer_seek( cx->producer, need_first * mlt_profile_fps( cx->profile ) - / mlt_producer_get_fps( this ) ); + mlt_producer_seek( cx->producer, + lrint( need_first * mlt_profile_fps( cx->profile ) / mlt_producer_get_fps( this ) ) ); // Get the nested frame mlt_frame nested_frame = mlt_consumer_rt_frame( cx->consumer );