diff options
author | Diego Biurrun <diego@biurrun.de> | 2016-12-03 13:16:13 +0100 |
---|---|---|
committer | Diego Biurrun <diego@biurrun.de> | 2016-12-11 09:27:40 +0100 |
commit | a6901b9c6bd51396c1159f1a07f9f5042328cda6 (patch) | |
tree | 5b0b328275737835e923f5903e7bfca206d9bded /libavcodec/mpegvideo_enc.c | |
parent | ac648bb835edd3f67bda2267d0e72e5e582eb5a1 (diff) | |
download | ffmpeg-a6901b9c6bd51396c1159f1a07f9f5042328cda6.tar.gz |
Drop libxvid rate control support for mpegvideo encoding
The feature has outlived is usefulness and complicates the code.
Diffstat (limited to 'libavcodec/mpegvideo_enc.c')
-rw-r--r-- | libavcodec/mpegvideo_enc.c | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c index 6a7c9e500f..40c044d703 100644 --- a/libavcodec/mpegvideo_enc.c +++ b/libavcodec/mpegvideo_enc.c @@ -60,7 +60,6 @@ #include "bytestream.h" #include "wmv2.h" #include "rv10.h" -#include "libxvid.h" #include <limits.h> #define QUANT_BIAS_SHIFT 8 @@ -872,28 +871,9 @@ FF_ENABLE_DEPRECATION_WARNINGS 31, 0); } -#if FF_API_RC_STRATEGY -FF_DISABLE_DEPRECATION_WARNINGS - if (!s->rc_strategy) - s->rc_strategy = s->avctx->rc_strategy; -FF_ENABLE_DEPRECATION_WARNINGS -#endif - if (ff_rate_control_init(s) < 0) return -1; - if ((s->avctx->flags & AV_CODEC_FLAG_PASS2) && s->rc_strategy == 1) { -#if CONFIG_LIBXVID - ret = ff_xvid_rate_control_init(s); -#else - ret = AVERROR(ENOSYS); - av_log(s->avctx, AV_LOG_ERROR, - "Xvid ratecontrol requires libavcodec compiled with Xvid support.\n"); -#endif - if (ret < 0) - return ret; - } - #if FF_API_ERROR_RATE FF_DISABLE_DEPRECATION_WARNINGS if (avctx->error_rate) @@ -987,11 +967,6 @@ av_cold int ff_mpv_encode_end(AVCodecContext *avctx) int i; ff_rate_control_uninit(s); -#if CONFIG_LIBXVID - if ((avctx->flags & AV_CODEC_FLAG_PASS2) && s->rc_strategy == 1) - ff_xvid_rate_control_uninit(s); -#endif - ff_mpv_common_end(s); if (CONFIG_MJPEG_ENCODER && s->out_format == FMT_MJPEG) @@ -3438,11 +3413,6 @@ static int estimate_qp(MpegEncContext *s, int dry_run){ if(!dry_run) s->next_lambda= 0; } else if (!s->fixed_qscale) { int quality; -#if CONFIG_LIBXVID - if ((s->avctx->flags & AV_CODEC_FLAG_PASS2) && s->rc_strategy == 1) - quality = ff_xvid_rate_estimate_qscale(s, dry_run); - else -#endif quality = ff_rate_estimate_qscale(s, dry_run); s->current_picture_ptr->f->quality = s->current_picture.f->quality = quality; |