diff options
-rw-r--r-- | DOCS/man/options.rst | 6 | ||||
-rw-r--r-- | demux/demux_mkv.c | 3 |
2 files changed, 8 insertions, 1 deletions
diff --git a/DOCS/man/options.rst b/DOCS/man/options.rst index 6e2dc5498a..74a623e6c5 100644 --- a/DOCS/man/options.rst +++ b/DOCS/man/options.rst @@ -3406,6 +3406,12 @@ Demuxer ``--demuxer-mkv-subtitle-preroll-secs-index=<value>`` See ``--demuxer-mkv-subtitle-preroll``. +``--demuxer-mkv-probe-start-time=<yes|no>`` + Check the start time of Matroska files (default: yes). This simply reads the + first cluster timestamps and assumes it is the start time. Technically, this + also reads the first timestamp, which may increase latency by one frame + (which may be relevant for live streams). + ``--demuxer-mkv-probe-video-duration=<yes|no|full>`` When opening the file, seek to the end of it, and check what timestamp the last video packet has, and report that as file duration. This is strictly diff --git a/demux/demux_mkv.c b/demux/demux_mkv.c index 99e481bc7d..a65afbfbc5 100644 --- a/demux/demux_mkv.c +++ b/demux/demux_mkv.c @@ -244,6 +244,7 @@ const struct m_sub_options demux_mkv_conf = { .subtitle_preroll = 2, .subtitle_preroll_secs = 1.0, .subtitle_preroll_secs_index = 10.0, + .probe_start_time = 1, }, }; @@ -3211,7 +3212,7 @@ static void probe_first_timestamp(struct demuxer *demuxer) demuxer->start_time = mkv_d->cluster_tc / 1e9; - if (demuxer->start_time > 0) + if (demuxer->start_time) MP_VERBOSE(demuxer, "Start PTS: %f\n", demuxer->start_time); } |