Commit 9e7b477c authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/ffv1enc: choose 1.2 by default for higher resolutions to ensure multi-threaded decodability

Reviewed-by: 's avatar"Peter B." <pb@das-werkstatt.com>
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent dcc9009e
......@@ -674,6 +674,10 @@ 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);
// Unspecified level & slices, we choose version 1.2+ to ensure multithreaded decodability
if (avctx->slices == 0 && avctx->level < 0 && avctx->width * avctx->height > 720*576)
s->version = FFMAX(s->version, 2);
if (avctx->level <= 0 && s->version == 2) {
s->version = 3;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment