summaryrefslogtreecommitdiff
path: root/libavcodec/libvpxenc.c
diff options
context:
space:
mode:
authorJames Zern <jzern@google.com>2015-04-21 00:03:00 -0700
committerJames Zern <jzern@google.com>2015-04-23 23:59:41 -0700
commit238ec505e263e7d0363798a05c1c28f494a6300a (patch)
tree23bb37a4bee3fc30da1ce60d970619087da5f2da /libavcodec/libvpxenc.c
parentacb07f33c40c2aaca7b26e5046048ca628643803 (diff)
libvpxenc: only set noise reduction w/vp8
this quiets a warning: Failed to set VP8E_SET_NOISE_SENSITIVITY codec control: Unspecified internal error Reviewed-by: Michael Niedermayer <michaelni@gmx.at> Signed-off-by: James Zern <jzern@google.com>
Diffstat (limited to 'libavcodec/libvpxenc.c')
-rw-r--r--libavcodec/libvpxenc.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/libavcodec/libvpxenc.c b/libavcodec/libvpxenc.c
index 21048764a0..159fbdd7ae 100644
--- a/libavcodec/libvpxenc.c
+++ b/libavcodec/libvpxenc.c
@@ -525,9 +525,10 @@ static av_cold int vpx_init(AVCodecContext *avctx,
codecctl_int(avctx, VP8E_SET_ARNR_STRENGTH, ctx->arnr_strength);
if (ctx->arnr_type >= 0)
codecctl_int(avctx, VP8E_SET_ARNR_TYPE, ctx->arnr_type);
- codecctl_int(avctx, VP8E_SET_NOISE_SENSITIVITY, avctx->noise_reduction);
- if (avctx->codec_id == AV_CODEC_ID_VP8)
+ if (avctx->codec_id == AV_CODEC_ID_VP8) {
+ codecctl_int(avctx, VP8E_SET_NOISE_SENSITIVITY, avctx->noise_reduction);
codecctl_int(avctx, VP8E_SET_TOKEN_PARTITIONS, av_log2(avctx->slices));
+ }
#if FF_API_MPV_OPT
FF_DISABLE_DEPRECATION_WARNINGS
if (avctx->mb_threshold) {