From 1ee7a2955f3ebd49a34ab4b9880889c4e0b5e423 Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Fri, 17 Aug 2012 17:11:24 +0200 Subject: [PATCH] libvpxenc: only force CBR if a bitrate is set Reviewed-by: James Zern Signed-off-by: Michael Niedermayer --- libavcodec/libvpxenc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/libvpxenc.c b/libavcodec/libvpxenc.c index 0b979072bb..b438301396 100644 --- a/libavcodec/libvpxenc.c +++ b/libavcodec/libvpxenc.c @@ -266,7 +266,7 @@ static av_cold int vp8_init(AVCodecContext *avctx) enccfg.g_pass = VPX_RC_ONE_PASS; if (avctx->rc_min_rate == avctx->rc_max_rate && - avctx->rc_min_rate == avctx->bit_rate) + avctx->rc_min_rate == avctx->bit_rate && avctx->bit_rate) enccfg.rc_end_usage = VPX_CBR; else if (ctx->crf) enccfg.rc_end_usage = VPX_CQ;