diff --git a/modules/video_coding/codecs/vp8/libvpx_vp8_encoder.cc b/modules/video_coding/codecs/vp8/libvpx_vp8_encoder.cc index 17220b14dd..d043768cc4 100644 --- a/modules/video_coding/codecs/vp8/libvpx_vp8_encoder.cc +++ b/modules/video_coding/codecs/vp8/libvpx_vp8_encoder.cc @@ -864,6 +864,7 @@ uint32_t LibvpxVp8Encoder::FrameDropThreshold(size_t spatial_idx) const { RTC_DCHECK(frame_buffer_controller_); RTC_DCHECK_LT(spatial_idx, frame_buffer_controller_->StreamCount()); enable_frame_dropping = + enable_frame_dropping && frame_buffer_controller_->SupportsEncoderFrameDropping(spatial_idx); return enable_frame_dropping ? 30 : 0; } diff --git a/modules/video_coding/codecs/vp8/test/vp8_impl_unittest.cc b/modules/video_coding/codecs/vp8/test/vp8_impl_unittest.cc index 2e2597e397..c257edd7c1 100644 --- a/modules/video_coding/codecs/vp8/test/vp8_impl_unittest.cc +++ b/modules/video_coding/codecs/vp8/test/vp8_impl_unittest.cc @@ -76,9 +76,6 @@ class TestVp8Impl : public VideoCodecUnitTest { webrtc::test::CodecSettings(kVideoCodecVP8, codec_settings); codec_settings->width = kWidth; codec_settings->height = kHeight; - codec_settings->VP8()->denoisingOn = true; - codec_settings->VP8()->frameDroppingOn = false; - codec_settings->VP8()->automaticResizeOn = false; codec_settings->VP8()->complexity = VideoCodecComplexity::kComplexityNormal; } @@ -408,7 +405,6 @@ TEST_F(TestVp8Impl, EncoderWith2TemporalLayers) { } TEST_F(TestVp8Impl, ScalingDisabledIfAutomaticResizeOff) { - codec_settings_.VP8()->frameDroppingOn = true; codec_settings_.VP8()->automaticResizeOn = false; EXPECT_EQ(WEBRTC_VIDEO_CODEC_OK, encoder_->InitEncode(&codec_settings_, kSettings)); @@ -419,7 +415,6 @@ TEST_F(TestVp8Impl, ScalingDisabledIfAutomaticResizeOff) { } TEST_F(TestVp8Impl, ScalingEnabledIfAutomaticResizeOn) { - codec_settings_.VP8()->frameDroppingOn = true; codec_settings_.VP8()->automaticResizeOn = true; EXPECT_EQ(WEBRTC_VIDEO_CODEC_OK, encoder_->InitEncode(&codec_settings_, kSettings));