diff options
author | wm4 <wm4@nowhere> | 2019-05-31 14:54:29 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2019-09-19 20:37:05 +0200 |
commit | ab19888ba49b52e80c1b9ba4aa305b6ee8548059 (patch) | |
tree | 2e4c39f2f3b9e86d25b70f8fb6e7b8de13ec4831 /misc/thread_pool.c | |
parent | af60a45fdfbf4384d34a9ade4347eed0ca98de71 (diff) | |
download | mpv-ab19888ba49b52e80c1b9ba4aa305b6ee8548059.tar.bz2 mpv-ab19888ba49b52e80c1b9ba4aa305b6ee8548059.tar.xz |
demux_mkv: don't set keyframe flag for timestamp-less audio frames
Matroska has this weird concept of "lacing", which are really sub-blocks
packed into a larger actual block. They are demuxed as individual
packets, because that's what the decoder needs. Basically they're a
Matroska hack to reduce per-packet muxing overhead.
One problem is that these sub-blocks don't have timestamps. The
timestamps need to be created from the "default duration". If this
default duration isn't in the file header (or if we drop it when it has
a known broken value), the resulting packets won't have a timestamp.
This is an usual and weird situation, that may confuse the demuxer layer
(and backward playback in particular). Fix this by not setting the
keyframe flag for these.
This affects only audio packets. Subtitle lacing is explicitly not
supported (in theory would at least lack a way to specify durations),
and video won't usually use it for real video codecs (not every frame is
a "keyframe", timestamp reordering).
Diffstat (limited to 'misc/thread_pool.c')
0 files changed, 0 insertions, 0 deletions