[vlc-commits] demux:mkv: remove some redundant cluster indexing calls
Steve Lhomme
git at videolan.org
Tue Jan 23 11:03:52 CET 2018
vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Tue Jan 23 11:03:48 2018 +0100| [7e8a3b48e9a54c9a25d056aaac08dbf1b72c5810] | committer: Steve Lhomme
demux:mkv: remove some redundant cluster indexing calls
We always add it to the index as soon as we have its timecode.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=7e8a3b48e9a54c9a25d056aaac08dbf1b72c5810
---
modules/demux/mkv/matroska_segment.cpp | 10 ++--------
modules/demux/mkv/matroska_segment.hpp | 1 -
2 files changed, 2 insertions(+), 9 deletions(-)
diff --git a/modules/demux/mkv/matroska_segment.cpp b/modules/demux/mkv/matroska_segment.cpp
index 096a5262ed..3c30ee51a7 100644
--- a/modules/demux/mkv/matroska_segment.cpp
+++ b/modules/demux/mkv/matroska_segment.cpp
@@ -464,11 +464,6 @@ void matroska_segment_c::InformationCreate( )
* Misc
*****************************************************************************/
-void matroska_segment_c::IndexAppendCluster( KaxCluster *cluster )
-{
- _seeker.add_cluster( cluster );
-}
-
bool matroska_segment_c::PreloadClusters(uint64 i_cluster_pos)
{
struct ClusterHandlerPayload
@@ -484,8 +479,7 @@ bool matroska_segment_c::PreloadClusters(uint64 i_cluster_pos)
E_CASE( KaxCluster, kcluster )
{
- if( vars.obj->ParseCluster( &kcluster, false ) )
- vars.obj->IndexAppendCluster( &kcluster );
+ vars.obj->ParseCluster( &kcluster, false );
}
E_CASE_DEFAULT( el )
@@ -1189,7 +1183,7 @@ int matroska_segment_c::BlockGet( KaxBlock * & pp_block, KaxSimpleBlock * & pp_s
{
ktimecode.ReadData( vars.obj->es.I_O(), SCOPE_ALL_DATA );
vars.obj->cluster->InitTimecode( static_cast<uint64>( ktimecode ), vars.obj->i_timescale );
- vars.obj->IndexAppendCluster( vars.obj->cluster );
+ vars.obj->_seeker.add_cluster( vars.obj->cluster );
vars.b_cluster_timecode = true;
}
E_CASE( KaxClusterSilentTracks, ksilent )
diff --git a/modules/demux/mkv/matroska_segment.hpp b/modules/demux/mkv/matroska_segment.hpp
index f2c9d3966c..8a0ac57c0d 100644
--- a/modules/demux/mkv/matroska_segment.hpp
+++ b/modules/demux/mkv/matroska_segment.hpp
@@ -166,7 +166,6 @@ private:
void ParseTrackEntry( const KaxTrackEntry* m );
bool ParseCluster( KaxCluster *cluster, bool b_update_start_time = true, ScopeMode read_fully = SCOPE_ALL_DATA );
bool ParseSimpleTags( SimpleTag* out, KaxTagSimple *tag, int level = 50 );
- void IndexAppendCluster( KaxCluster *cluster );
bool TrackInit( mkv_track_t * p_tk );
void ComputeTrackPriority();
void EnsureDuration();
More information about the vlc-commits
mailing list