[vlc-commits] transcode: update 'input pts' on loop so duplicate calculation can work properly with yadif2x etc
Ilkka Ollakka
git at videolan.org
Sun Feb 2 15:06:05 CET 2014
vlc | branch: master | Ilkka Ollakka <ileoo at videolan.org> | Sat Feb 1 15:06:33 2014 +0200| [ba60bd80da7cb866033c1e0a16b6fc8293725c84] | committer: Ilkka Ollakka
transcode: update 'input pts' on loop so duplicate calculation can work properly with yadif2x etc
'input pts' is the pts after all the filters, so for example yadif2x etc need to take into account.
It is used to determinate if we need to duplicate current block until we should get new picture
to encode.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=ba60bd80da7cb866033c1e0a16b6fc8293725c84
---
modules/stream_out/transcode/video.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/modules/stream_out/transcode/video.c b/modules/stream_out/transcode/video.c
index 0c811ca..00a44f9 100644
--- a/modules/stream_out/transcode/video.c
+++ b/modules/stream_out/transcode/video.c
@@ -930,8 +930,6 @@ int transcode_video_process( sout_stream_t *p_stream, sout_stream_id_t *id,
/* Set the pts of the frame being encoded */
p_pic->date = i_pts;
- /* now take next input pts, pts dates are only enabled if p_module is set*/
- date_Increment( &id->interpolated_pts, id->p_decoder->fmt_out.video.i_frame_rate_base );
/* If input pts + input_frame_interval is lower than next_output_pts - output_frame_interval
@@ -979,6 +977,9 @@ int transcode_video_process( sout_stream_t *p_stream, sout_stream_id_t *id,
if( !p_user_filtered_pic )
break;
+ /* now take next input pts, pts dates are only enabled if p_module is set*/
+ date_Increment( &id->interpolated_pts, id->p_decoder->fmt_out.video.i_frame_rate_base );
+
OutputFrame( p_sys, p_user_filtered_pic, p_stream, id, out );
p_filtered_pic = NULL;
More information about the vlc-commits
mailing list