[vlc-devel] [PATCH 03/11] mkv: add cluster position info from cues

Filip Roséen filip at videolabs.io
Sat May 21 02:17:55 CEST 2016


Every cue in the matroska format is based on the location of the cluster
in which it is part of, as such we should add this information (cluster
position) to the code responsible for seeking.
---
 modules/demux/mkv/matroska_segment.cpp | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/modules/demux/mkv/matroska_segment.cpp b/modules/demux/mkv/matroska_segment.cpp
index 07c431e..66198e5 100644
--- a/modules/demux/mkv/matroska_segment.cpp
+++ b/modules/demux/mkv/matroska_segment.cpp
@@ -168,6 +168,8 @@ void matroska_segment_c::LoadCues( KaxCues *cues )
                             {
                                 kccp_ptr->ReadData( es.I_O() );
                                 cue_position = segment->GetGlobalPosition( static_cast<uint64>( *kccp_ptr ) );
+
+                                _seeker.add_cluster_position( cue_position );
                             }
                             else if( MKV_CHECKED_PTR_DECL ( kcbn_ptr, KaxCueBlockNumber, el ) )
                             {
-- 
2.8.2



More information about the vlc-devel mailing list