You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-11-23 21:54:53 +02:00
avcodec/tests/avcodec: Test that decoders don't set encoder-only fields
For decoders, the pixel format is negotiated via the get_format callback (if there is a choice at all), so decoders should not set pix_fmts. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
committed by
James Almer
parent
2523235a31
commit
e9be8b831d
@@ -185,6 +185,10 @@ FF_ENABLE_DEPRECATION_WARNINGS
|
||||
codec2->caps_internal & FF_CODEC_CAP_SETS_PKT_DTS)
|
||||
ERR("Decoder %s is marked as setting pkt_dts when it doesn't have"
|
||||
"any effect\n");
|
||||
FF_DISABLE_DEPRECATION_WARNINGS
|
||||
if (codec->type == AVMEDIA_TYPE_VIDEO && (codec->pix_fmts || codec->supported_framerates))
|
||||
ERR("Decoder %s sets pix_fmts or supported_framerates.\n");
|
||||
FF_ENABLE_DEPRECATION_WARNINGS
|
||||
}
|
||||
if (priv_data_size_wrong(codec2))
|
||||
ERR_EXT("Private context of codec %s is impossibly-sized (size %d).",
|
||||
|
||||
Reference in New Issue
Block a user