mkv: add every seen subtitle block as seekpoint

Multimedia / VLC - Filip Roséen [videolabs.io] - 9 May 2016 08:09 UTC

Currently there are issues outside of the demuxer that does not allow us to display an "on-going" subtitle if we seek to a location where a subtitle has started, but yet finished.

Since there are several mkv files in the wild where there is no proper mkv-cue for every subtitle, we should add every subtitle block we see as an index; and then use this for seeking (if we know about it, and have to).

In general, every subtitle block is effectively a "keyframe"; meaning that this hack is safe (at least enough to justify its purpose). Having seekpoints for the subtitle track will allow us to send it to the relevant decoder, and after we have support for "unfinished" subtitles; mkv's will magically play along nicely.

2dba57c mkv: add every seen subtitle block as seekpoint
modules/demux/mkv/matroska_segment.cpp | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)

Upstream: git.videolan.org


  • Share