From 520fc7403621156676b1ca183aed4911bf6c47b5 Mon Sep 17 00:00:00 2001 From: wm4 Date: Thu, 7 Dec 2017 10:20:03 +0100 Subject: player: rebase start time even for subtitle streams It appears libavformat never sets the file start time for subtitles, so this special check is not needed. The original idea was probably that _if_ the demuxer set the start time to the first subtitle packet, the subtitles would be shifted incorrectly. --- player/loadfile.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'player/loadfile.c') diff --git a/player/loadfile.c b/player/loadfile.c index 46f5d4e4f3..674902e9be 100644 --- a/player/loadfile.c +++ b/player/loadfile.c @@ -598,7 +598,7 @@ struct track *mp_add_external_file(struct MPContext *mpctx, char *filename, goto err_out; enable_demux_thread(mpctx, demuxer); - if (filter != STREAM_SUB && opts->rebase_start_time) + if (opts->rebase_start_time) demux_set_ts_offset(demuxer, -demuxer->start_time); struct track *first = NULL; -- cgit v1.2.3