diff options
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/ffv1enc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/ffv1enc.c b/libavcodec/ffv1enc.c index faf64ca780..6baa7e97bf 100644 --- a/libavcodec/ffv1enc.c +++ b/libavcodec/ffv1enc.c @@ -651,7 +651,7 @@ static av_cold int encode_init(AVCodecContext *avctx) if ((avctx->flags & (CODEC_FLAG_PASS1|CODEC_FLAG_PASS2)) || avctx->slices>1) s->version = FFMAX(s->version, 2); - if (avctx->level == 3 || (s->version==2 && avctx->strict_std_compliance > FF_COMPLIANCE_EXPERIMENTAL)) { + if (avctx->level == 3 || (avctx->level <= 0 && s->version == 2)) { s->version = 3; } @@ -659,7 +659,7 @@ static av_cold int encode_init(AVCodecContext *avctx) s->ec = (s->version >= 3); } - if (s->version >= 2 && avctx->strict_std_compliance > FF_COMPLIANCE_EXPERIMENTAL) { + if ((s->version == 2 || s->version>3) && avctx->strict_std_compliance > FF_COMPLIANCE_EXPERIMENTAL) { av_log(avctx, AV_LOG_ERROR, "Version 2 needed for requested features but version 2 is experimental and not enabled\n"); return AVERROR_INVALIDDATA; } |