[vlc-commits] transcode:audio: simplify code to reset the master sync
Steve Lhomme
git at videolan.org
Wed May 2 18:42:18 CEST 2018
vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Wed May 2 17:25:05 2018 +0200| [fe499f7cefd68e97fe9006ab3bfd6cafce0acdc1] | committer: Steve Lhomme
transcode:audio: simplify code to reset the master sync
id->next_input_pts and p_audio_buf->i_pts are the same after the date_Set().
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=fe499f7cefd68e97fe9006ab3bfd6cafce0acdc1
---
modules/stream_out/transcode/audio.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/modules/stream_out/transcode/audio.c b/modules/stream_out/transcode/audio.c
index aeb42b9ee7..055473198b 100644
--- a/modules/stream_out/transcode/audio.c
+++ b/modules/stream_out/transcode/audio.c
@@ -355,9 +355,8 @@ int transcode_audio_process( sout_stream_t *p_stream,
"audio drift is too high (%"PRId64"), resetting master sync",
i_drift );
date_Set( &id->next_input_pts, p_audio_buf->i_pts );
- i_pts = date_Get( &id->next_input_pts );
if( likely(p_audio_buf->i_pts != VLC_TS_INVALID ) )
- i_drift = p_audio_buf->i_pts - i_pts;
+ i_drift = 0;
}
p_sys->i_master_drift = i_drift;
date_Increment( &id->next_input_pts, p_audio_buf->i_nb_samples );
More information about the vlc-commits
mailing list