diff --git a/src/modules/video_coding/codecs/vp8/main/source/vp8.cc b/src/modules/video_coding/codecs/vp8/main/source/vp8.cc index d9ad5c1e9..92e5c7285 100644 --- a/src/modules/video_coding/codecs/vp8/main/source/vp8.cc +++ b/src/modules/video_coding/codecs/vp8/main/source/vp8.cc @@ -67,7 +67,7 @@ VP8Encoder::~VP8Encoder() WebRtc_Word32 VP8Encoder::VersionStatic(WebRtc_Word8* version, WebRtc_Word32 length) { - const WebRtc_Word8* str = "WebM/VP8 version 1.0.0\n"; // Bali + const WebRtc_Word8* str = "WebM/VP8 version 1.0.0\n"; WebRtc_Word32 verLen = (WebRtc_Word32)strlen(str); if (verLen > length) { @@ -345,8 +345,10 @@ VP8Encoder::InitAndSetControlSettings() } vpx_codec_control(_encoder, VP8E_SET_STATIC_THRESHOLD, 800); vpx_codec_control(_encoder, VP8E_SET_CPUUSED, _cpuSpeed); +#if WEBRTC_LIBVPX_VERSION >= 971 vpx_codec_control(_encoder, VP8E_SET_MAX_INTRA_BITRATE_PCT, _rcMaxIntraTarget); +#endif *_cfg = cfg_copy; _inited = true; @@ -656,7 +658,10 @@ VP8Decoder::InitDecode(const VideoCodec* inst, cfg.threads = numberOfCores; cfg.h = cfg.w = 0; // set after decode - vpx_codec_flags_t flags = VPX_CODEC_USE_ERROR_CONCEALMENT; + vpx_codec_flags_t flags = 0; +#if WEBRTC_LIBVPX_VERSION >= 971 + flags = VPX_CODEC_USE_ERROR_CONCEALMENT; +#endif if (vpx_codec_dec_init(_decoder, vpx_codec_vp8_dx(), NULL, flags)) { diff --git a/src/modules/video_coding/codecs/vp8/main/source/vp8.gyp b/src/modules/video_coding/codecs/vp8/main/source/vp8.gyp index 4f7aeb8f4..083845e02 100644 --- a/src/modules/video_coding/codecs/vp8/main/source/vp8.gyp +++ b/src/modules/video_coding/codecs/vp8/main/source/vp8.gyp @@ -47,6 +47,9 @@ ], }], ], + 'defines': [ + 'WEBRTC_LIBVPX_VERSION=960' # Bali + ], },{ 'dependencies': [ '../../../../../../../third_party/libvpx/libvpx.gyp:libvpx', @@ -54,6 +57,9 @@ 'include_dirs': [ '../../../../../../../third_party/libvpx/source/libvpx', ], + 'defines': [ + 'WEBRTC_LIBVPX_VERSION=971' # Cayuga + ], }], ], 'direct_dependent_settings': {