mirror of
https://git.videolan.org/git/ffmpeg.git
synced 2024-09-10 09:31:06 +02:00
avcodec/ffv1enc: Fix storing RGB48 without explicitly set level
the bps value is only stored with level >= 1, using rgb48 with level 0 requires the user app to keep track of the bps by external means, which does not always happen also we force level >= 1 for other 16bps formats, so this is consistent. Found-by: Jerome Martinez <jerome@mediaarea.net> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
ba53d3ae8b
commit
c1173437fc
@ -629,6 +629,7 @@ FF_ENABLE_DEPRECATION_WARNINGS
|
|||||||
s->chroma_planes = 1;
|
s->chroma_planes = 1;
|
||||||
s->bits_per_raw_sample = 16;
|
s->bits_per_raw_sample = 16;
|
||||||
s->use32bit = 1;
|
s->use32bit = 1;
|
||||||
|
s->version = FFMAX(s->version, 1);
|
||||||
if (avctx->strict_std_compliance > FF_COMPLIANCE_EXPERIMENTAL) {
|
if (avctx->strict_std_compliance > FF_COMPLIANCE_EXPERIMENTAL) {
|
||||||
av_log(avctx, AV_LOG_ERROR, "16bit RGB is experimental and under development, only use it for experiments\n");
|
av_log(avctx, AV_LOG_ERROR, "16bit RGB is experimental and under development, only use it for experiments\n");
|
||||||
return AVERROR_INVALIDDATA;
|
return AVERROR_INVALIDDATA;
|
||||||
|
Loading…
Reference in New Issue
Block a user