summaryrefslogtreecommitdiff
path: root/libavcodec/mpegvideo_enc.c
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2012-02-27 19:09:49 +0100
committerAnton Khirnov <anton@khirnov.net>2012-02-29 07:23:31 +0100
commit63efd83ae10a158e3ae0823e3527f3845dda397a (patch)
tree6d0031e3c22a062d4777be4183627143f59c20eb /libavcodec/mpegvideo_enc.c
parentaf3d804f9feebe34ad3815c501fba795b801cdd0 (diff)
mpegvideo_enc: add chroma/luma_elim_threshold private options.
Deprecate corresponding AVCodecContext fields.
Diffstat (limited to 'libavcodec/mpegvideo_enc.c')
-rw-r--r--libavcodec/mpegvideo_enc.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c
index e6e6a95b48..8a516b3016 100644
--- a/libavcodec/mpegvideo_enc.c
+++ b/libavcodec/mpegvideo_enc.c
@@ -353,8 +353,12 @@ av_cold int ff_MPV_encode_init(AVCodecContext *avctx)
s->flags2 = avctx->flags2;
s->max_b_frames = avctx->max_b_frames;
s->codec_id = avctx->codec->id;
- s->luma_elim_threshold = avctx->luma_elim_threshold;
- s->chroma_elim_threshold = avctx->chroma_elim_threshold;
+#if FF_API_MPV_GLOBAL_OPTS
+ if (avctx->luma_elim_threshold)
+ s->luma_elim_threshold = avctx->luma_elim_threshold;
+ if (avctx->chroma_elim_threshold)
+ s->chroma_elim_threshold = avctx->chroma_elim_threshold;
+#endif
s->strict_std_compliance = avctx->strict_std_compliance;
s->quarter_sample = (avctx->flags & CODEC_FLAG_QPEL) != 0;
s->mpeg_quant = avctx->mpeg_quant;