Skip to content

Commit

Permalink
demux: mkv: fix seek
Browse files Browse the repository at this point in the history
This fixes a regression from 6b10c2e. Seek failed due to empty
_tracks_seekpoints[video_track].
  • Loading branch information
quink-black authored and robUx4 committed Jul 2, 2018
1 parent c784e8c commit 7bbfee8
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions modules/demux/mkv/matroska_segment.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -635,6 +635,16 @@ bool matroska_segment_c::Preload( )


cluster = kc_ptr;

// add first cluster as trusted seekpoint for all tracks
for( tracks_map_t::const_iterator it = tracks.begin();
it != tracks.end(); ++it )
{
_seeker.add_seekpoint( it->first,
SegmentSeeker::Seekpoint( cluster->GetElementPosition(), -1,
SegmentSeeker::Seekpoint::TrustLevel::QUESTIONABLE ) );
}

/* stop pre-parsing the stream */
break;
}
Expand Down

0 comments on commit 7bbfee8

Please sign in to comment.