demux_timeline: request subtitle prefetching on crossing segments

SEEK_HR is interpreted by demux_mkv.c, and enables subtitle preroll by
prefetching additional subtitle pakcets which might overlap with the
seek destination. This should make the case work when segment boundaries
fall into the middle of subtitle events.

This still usually leaves a flicker of at least 1 frame on start,
because dec_sub.c does not ensure that enough subtitles are read before
rendering after a segment switch. (Probably a WONTFIX.)
This commit is contained in:
wm4 2016-03-25 17:27:02 +01:00
parent ef625a78a4
commit dafafc90de
1 changed files with 1 additions and 1 deletions

View File

@ -96,7 +96,7 @@ static void switch_segment(struct demuxer *demuxer, struct segment *new,
bool new_segment = p->current != new;
if (!(flags & (SEEK_FORWARD | SEEK_BACKWARD)))
flags |= SEEK_BACKWARD;
flags |= SEEK_BACKWARD | SEEK_HR;
MP_VERBOSE(demuxer, "switch to segment %d\n", new->index);