diff --git a/webrtc/modules/video_coding/codecs/vp8/vp8_impl.cc b/webrtc/modules/video_coding/codecs/vp8/vp8_impl.cc index 9d64ef19ee..9d7367b153 100644 --- a/webrtc/modules/video_coding/codecs/vp8/vp8_impl.cc +++ b/webrtc/modules/video_coding/codecs/vp8/vp8_impl.cc @@ -269,7 +269,7 @@ int VP8EncoderImpl::InitEncode(const VideoCodec* inst, cpu_speed_ = -6; break; } -#ifdef WEBRTC_ANDROID +#if defined(WEBRTC_ARCH_ARM) // On mobile platform, always set to -12 to leverage between cpu usage // and video quality cpu_speed_ = -12; @@ -294,8 +294,11 @@ int VP8EncoderImpl::InitAndSetControlSettings(const VideoCodec* inst) { vpx_codec_control(encoder_, VP8E_SET_CPUUSED, cpu_speed_); vpx_codec_control(encoder_, VP8E_SET_TOKEN_PARTITIONS, static_cast(token_partitions_)); +#if !defined(WEBRTC_ARCH_ARM) + // TODO(fbarchard): Enable Noise reduction for ARM once optimized. vpx_codec_control(encoder_, VP8E_SET_NOISE_SENSITIVITY, inst->codecSpecific.VP8.denoisingOn ? 1 : 0); +#endif #if WEBRTC_LIBVPX_VERSION >= 971 vpx_codec_control(encoder_, VP8E_SET_MAX_INTRA_BITRATE_PCT, rc_max_intra_target_); @@ -626,7 +629,7 @@ int VP8DecoderImpl::InitDecode(const VideoCodec* inst, int number_of_cores) { cfg.h = cfg.w = 0; // set after decode vpx_codec_flags_t flags = 0; -#if (WEBRTC_LIBVPX_VERSION >= 971) && !defined(WEBRTC_ANDROID) +#if (WEBRTC_LIBVPX_VERSION >= 971) && !defined(WEBRTC_ARCH_ARM) flags = VPX_CODEC_USE_POSTPROC; if (inst->codecSpecific.VP8.errorConcealmentOn) { flags |= VPX_CODEC_USE_ERROR_CONCEALMENT; @@ -640,7 +643,7 @@ int VP8DecoderImpl::InitDecode(const VideoCodec* inst, int number_of_cores) { return WEBRTC_VIDEO_CODEC_MEMORY; } -#if (WEBRTC_LIBVPX_VERSION >= 971) && !defined(WEBRTC_ANDROID) +#if (WEBRTC_LIBVPX_VERSION >= 971) && !defined(WEBRTC_ARCH_ARM) vp8_postproc_cfg_t ppcfg; ppcfg.post_proc_flag = VP8_DEMACROBLOCK | VP8_DEBLOCK; // Strength of deblocking filter. Valid range:[0,16] @@ -681,7 +684,7 @@ int VP8DecoderImpl::Decode(const EncodedImage& input_image, } #endif -#if (WEBRTC_LIBVPX_VERSION >= 971) && !defined(WEBRTC_ANDROID) +#if (WEBRTC_LIBVPX_VERSION >= 971) && !defined(WEBRTC_ARCH_ARM) if (!mfqe_enabled_ && codec_specific_info && codec_specific_info->codecSpecific.VP8.temporalIdx > 0) { // Enable MFQE if we are receiving layers.