mirror of
https://github.com/mpv-player/mpv.git
synced 2025-12-26 21:00:21 +00:00
demux_mkv: trust keyframe flags for TrueHD
TrueHD is a fucked up audio codec with extremely small frame sizes. Some of these frames start with full headers, which are usually marked as keyframes, and from which decoding can be started (or at least that's what you'd expect). So for such tracks we should probably trust the keyframe flags. Doesn't really improve seek behavior, though.
This commit is contained in:
@@ -1756,7 +1756,8 @@ static int demux_mkv_open_audio(demuxer_t *demuxer, mkv_track_t *track)
|
||||
|
||||
// Deal with some FFmpeg-produced garbage, and assume all audio codecs can
|
||||
// start decoding from anywhere.
|
||||
track->require_keyframes = true;
|
||||
if (strcmp(codec, "truehd") != 0)
|
||||
track->require_keyframes = true;
|
||||
|
||||
sh_a->extradata = extradata;
|
||||
sh_a->extradata_size = extradata_len;
|
||||
|
||||
Reference in New Issue
Block a user