From 910247f1720c6aae422723c05dac6d0b19f20bec Mon Sep 17 00:00:00 2001 From: Vittorio Giovara Date: Thu, 2 Jul 2015 12:14:22 +0100 Subject: lavc: Deprecate avctx.{inter,intra}_quant_bias They are used by dnxhd and mpegvideo_enc exclusively, move them to codec private options instead. Signed-off-by: Vittorio Giovara --- libavcodec/mpegvideo_enc.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'libavcodec/mpegvideo_enc.c') diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c index 7975dd2277..f88e0096b4 100644 --- a/libavcodec/mpegvideo_enc.c +++ b/libavcodec/mpegvideo_enc.c @@ -542,10 +542,16 @@ av_cold int ff_mpv_encode_init(AVCodecContext *avctx) s->inter_quant_bias = -(1 << (QUANT_BIAS_SHIFT - 2)); } - if (avctx->intra_quant_bias != FF_DEFAULT_QUANT_BIAS) +#if FF_API_QUANT_BIAS +FF_DISABLE_DEPRECATION_WARNINGS + if (s->intra_quant_bias == FF_DEFAULT_QUANT_BIAS && + avctx->intra_quant_bias != FF_DEFAULT_QUANT_BIAS) s->intra_quant_bias = avctx->intra_quant_bias; - if (avctx->inter_quant_bias != FF_DEFAULT_QUANT_BIAS) + if (s->inter_quant_bias == FF_DEFAULT_QUANT_BIAS && + avctx->inter_quant_bias != FF_DEFAULT_QUANT_BIAS) s->inter_quant_bias = avctx->inter_quant_bias; +FF_ENABLE_DEPRECATION_WARNINGS +#endif if (avctx->codec_id == AV_CODEC_ID_MPEG4 && s->avctx->time_base.den > (1 << 16) - 1) { -- cgit v1.2.3