You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-11-23 21:54:53 +02:00
vc1_parser: Reset unesc_index after extracting header with complete frames
When PARSER_FLAG_COMPLETE_FRAMES is set (e.g. in Matroska), unesc_index is not reset after the first frame, which causes subsequent frames to inherit leftover header data. This leads to incorrect keyframe marking and broken decoding. See also this bug report: https://trac.ffmpeg.org/ticket/8515 Signed-off-by: DE-AI <max.christoph@pentaxmedical.com>
This commit is contained in:
@@ -179,6 +179,7 @@ static int vc1_parse(AVCodecParserContext *s,
|
||||
// start codes if we know it contains a complete frame and
|
||||
// we've already unescaped all we need of the frame header
|
||||
vc1_extract_header(s, avctx, unesc_buffer, unesc_index);
|
||||
unesc_index = 0;
|
||||
break;
|
||||
}
|
||||
if (unesc_index >= UNESCAPED_THRESHOLD && !start_code_found) {
|
||||
|
||||
Reference in New Issue
Block a user