1
mirror of https://github.com/mpv-player/mpv synced 2024-11-14 22:48:35 +01:00

player: do not rebase start time for subtitle streams

As stated in the original commit message, if the demuxer set the start
time to the first subtitle packet, the subtitles would be shifted
incorrectly. It appears that it is the case for external PGS subtitles.

This reverts commit 520fc74036.

Fixes #5485
This commit is contained in:
zc62 2019-02-18 08:01:29 -05:00 committed by sfan5
parent 537006965e
commit d38c4879d7

View File

@ -609,7 +609,7 @@ int mp_add_external_file(struct MPContext *mpctx, char *filename,
goto err_out;
enable_demux_thread(mpctx, demuxer);
if (opts->rebase_start_time)
if (filter != STREAM_SUB && opts->rebase_start_time)
demux_set_ts_offset(demuxer, -demuxer->start_time);
bool has_any = false;