[vlc-devel] [PATCH 04/10] aout: dts = pts for aout modules

Thomas Guillem thomas at gllm.fr
Tue Mar 19 17:45:19 CET 2019


Like it's already done for aout_DecSilence().
---
 src/audio_output/dec.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/audio_output/dec.c b/src/audio_output/dec.c
index ae686f2dc2..cae2068805 100644
--- a/src/audio_output/dec.c
+++ b/src/audio_output/dec.c
@@ -463,6 +463,7 @@ int aout_DecPlay(audio_output_t *aout, block_t *block)
                                   owner->sync.rate);
     /* Output */
     owner->sync.discontinuity = false;
+    block->i_dts = block->i_pts;
     aout->play(aout, block, play_date);
 
     atomic_fetch_add_explicit(&owner->buffers_played, 1, memory_order_relaxed);
@@ -552,7 +553,10 @@ void aout_DecDrain(audio_output_t *aout)
 
     block_t *block = aout_FiltersDrain (owner->filters);
     if (block)
+    {
+        block->i_dts = block->i_pts;
         aout->play(aout, block, vlc_tick_now());
+    }
 
     vlc_clock_Reset(owner->sync.clock);
     aout_FiltersResetClock(owner->filters);
-- 
2.20.1



More information about the vlc-devel mailing list