[vlc-devel] [PATCH 4/5] mkv: call ES_OUT_RESET_PCR when seeking in the segment

Steve Lhomme robux4 at videolabs.io
Thu Mar 17 17:47:19 CET 2016


---
 modules/demux/mkv/demux.cpp | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/modules/demux/mkv/demux.cpp b/modules/demux/mkv/demux.cpp
index ca50504..f06cf7b 100644
--- a/modules/demux/mkv/demux.cpp
+++ b/modules/demux/mkv/demux.cpp
@@ -798,6 +798,7 @@ bool demux_sys_t::PreparePlayback( virtual_segment_c & new_vsegment, mtime_t i_m
     p_current_vsegment->CurrentSegment()->Select( i_mk_date );
 
     /* Seek to the beginning */
+    es_out_Control( p_current_vsegment->CurrentSegment()->sys.demuxer.out, ES_OUT_RESET_PCR);
     p_current_vsegment->Seek(p_current_vsegment->CurrentSegment()->sys.demuxer,
                              i_mk_date, p_current_vsegment->p_current_vchapter, -1);
 
@@ -809,6 +810,7 @@ void demux_sys_t::JumpTo( virtual_segment_c & vsegment, virtual_chapter_c & vcha
     if ( !vchapter.p_chapter || !vchapter.p_chapter->Enter( true ) )
     {
         // jump to the location in the found segment
+        es_out_Control( demuxer.out, ES_OUT_RESET_PCR);
         vsegment.Seek( demuxer, vchapter.i_mk_virtual_start_time, &vchapter, -1 );
     }
 }
-- 
2.7.1



More information about the vlc-devel mailing list