Remove wire-up for cancelled experement on VAAPI VP8 encoding
This experiment is now wired up inside of chrome using field trial and this passthrough is now obsolete. Bug: chromium:794608 Change-Id: I1407e391d39c7e8696add9f656f059e7d8a27a08 Reviewed-on: https://webrtc-review.googlesource.com/82780 Reviewed-by: Per Kjellander <perkj@webrtc.org> Reviewed-by: Erik Språng <sprang@webrtc.org> Reviewed-by: Niels Moller <nisse@webrtc.org> Commit-Queue: Ilya Nikolaevskiy <ilnik@webrtc.org> Cr-Commit-Position: refs/heads/master@{#23625}
This commit is contained in:

committed by
Commit Bot

parent
d264df587f
commit
fc9dcb6a00
@ -340,15 +340,6 @@ class PeerConnectionInterface : public rtc::RefCountInterface {
|
||||
media_config.video.experiment_cpu_load_estimator = enable;
|
||||
}
|
||||
|
||||
// Hardware VP8 encoding using VA-API on intel kaby-lake processors.
|
||||
// crbug.com/794608
|
||||
bool experiment_vaapi_vp8_hw_encoding() const {
|
||||
return media_config.video.experiment_vaapi_vp8_hw_encoding;
|
||||
}
|
||||
void set_experiment_vaapi_vp8_hw_encoding(bool enable) {
|
||||
media_config.video.experiment_vaapi_vp8_hw_encoding = enable;
|
||||
}
|
||||
|
||||
static const int kUndefined = -1;
|
||||
// Default maximum number of packets in the audio jitter buffer.
|
||||
static const int kAudioJitterBufferMaxPackets = 50;
|
||||
|
@ -114,11 +114,6 @@ class VideoSendStream {
|
||||
// cpu adaptation.
|
||||
bool experiment_cpu_load_estimator = false;
|
||||
|
||||
// Enables hardware VAAPI VP8 encoding if supported by the provided
|
||||
// VideoEncoderFactory.
|
||||
// TODO(ilnik): remove this when VAAPI VP8 experiment is over.
|
||||
bool experiment_vaapi_vp8_hw_encoding = false;
|
||||
|
||||
// Ownership stays with WebrtcVideoEngine (delegated from PeerConnection).
|
||||
VideoEncoderFactory* encoder_factory = nullptr;
|
||||
} encoder_settings;
|
||||
|
@ -59,11 +59,6 @@ struct MediaConfig {
|
||||
// TODO(bugs.webrtc.org/8504): If all goes well, the flag will be removed
|
||||
// together with the old method of estimation.
|
||||
bool experiment_cpu_load_estimator = false;
|
||||
|
||||
// Enables experimental VAAPI VP8 hardware encoder, if supported by the
|
||||
// provided VideoEncoderFactory.
|
||||
// TODO(ilnik): remove this when VAAPI VP8 experiment is over.
|
||||
bool experiment_vaapi_vp8_hw_encoding = false;
|
||||
} video;
|
||||
|
||||
bool operator==(const MediaConfig& o) const {
|
||||
@ -76,9 +71,7 @@ struct MediaConfig {
|
||||
video.periodic_alr_bandwidth_probing ==
|
||||
o.video.periodic_alr_bandwidth_probing &&
|
||||
video.experiment_cpu_load_estimator ==
|
||||
o.video.experiment_cpu_load_estimator &&
|
||||
video.experiment_vaapi_vp8_hw_encoding ==
|
||||
o.video.experiment_vaapi_vp8_hw_encoding;
|
||||
o.video.experiment_cpu_load_estimator;
|
||||
}
|
||||
|
||||
bool operator!=(const MediaConfig& o) const { return !(*this == o); }
|
||||
|
@ -1124,8 +1124,6 @@ bool WebRtcVideoChannel::AddSendStream(const StreamParams& sp) {
|
||||
video_config_.periodic_alr_bandwidth_probing;
|
||||
config.encoder_settings.experiment_cpu_load_estimator =
|
||||
video_config_.experiment_cpu_load_estimator;
|
||||
config.encoder_settings.experiment_vaapi_vp8_hw_encoding =
|
||||
video_config_.experiment_vaapi_vp8_hw_encoding;
|
||||
config.encoder_settings.encoder_factory = encoder_factory_;
|
||||
|
||||
WebRtcVideoSendStream* stream = new WebRtcVideoSendStream(
|
||||
|
@ -4043,7 +4043,6 @@ TEST_F(PeerConnectionMediaConfigTest, TestDefaults) {
|
||||
EXPECT_TRUE(media_config.video.enable_prerenderer_smoothing);
|
||||
EXPECT_FALSE(media_config.video.suspend_below_min_bitrate);
|
||||
EXPECT_FALSE(media_config.video.experiment_cpu_load_estimator);
|
||||
EXPECT_FALSE(media_config.video.experiment_vaapi_vp8_hw_encoding);
|
||||
}
|
||||
|
||||
// This test verifies the DSCP constraint is recognized and passed to
|
||||
@ -4099,19 +4098,6 @@ TEST_F(PeerConnectionMediaConfigTest, TestEnableExperimentCpuLoadEstimator) {
|
||||
EXPECT_TRUE(media_config.video.experiment_cpu_load_estimator);
|
||||
}
|
||||
|
||||
// This test verifies that the experiment_vaapi_vp8_hw_encoding flag is
|
||||
// propagated from RTCConfiguration to the PeerConnection.
|
||||
TEST_F(PeerConnectionMediaConfigTest, TestEnableExperimentVaapiVp8HwEncoding) {
|
||||
PeerConnectionInterface::RTCConfiguration config;
|
||||
FakeConstraints constraints;
|
||||
|
||||
config.set_experiment_vaapi_vp8_hw_encoding(true);
|
||||
const cricket::MediaConfig& media_config =
|
||||
TestCreatePeerConnection(config, &constraints);
|
||||
|
||||
EXPECT_TRUE(media_config.video.experiment_vaapi_vp8_hw_encoding);
|
||||
}
|
||||
|
||||
// This test verifies the suspend below min bitrate constraint is
|
||||
// recognized and passed to the PeerConnection.
|
||||
TEST_F(PeerConnectionMediaConfigTest,
|
||||
|
@ -36,13 +36,6 @@ namespace webrtc {
|
||||
|
||||
namespace {
|
||||
|
||||
// This artificial SDP parameter is used to pass the experiment status to
|
||||
// video encoder factory. It's added explicitly before call to
|
||||
// |CreateVideoEncoder()| with value "Enabled" if experiment is enabled.
|
||||
// TODO(ilnik): remove this when VAAPI VP8 experiment is over.
|
||||
const char kExprimentVaapiVp8HwEncodingParameter[] =
|
||||
"ExprimentVaapiVp8HwEncoding";
|
||||
|
||||
// Time interval for logging frame counts.
|
||||
const int64_t kFrameLogIntervalMs = 60000;
|
||||
const int kMinFramerateFps = 2;
|
||||
@ -550,13 +543,8 @@ void VideoStreamEncoder::ReconfigureEncoder() {
|
||||
video_sender_.RegisterExternalEncoder(nullptr, false);
|
||||
}
|
||||
|
||||
SdpVideoFormat video_format = encoder_config_.video_format;
|
||||
if (video_format.name == "VP8" &&
|
||||
settings_.experiment_vaapi_vp8_hw_encoding) {
|
||||
video_format.parameters[kExprimentVaapiVp8HwEncodingParameter] =
|
||||
"Enabled";
|
||||
}
|
||||
encoder_ = settings_.encoder_factory->CreateVideoEncoder(video_format);
|
||||
encoder_ = settings_.encoder_factory->CreateVideoEncoder(
|
||||
encoder_config_.video_format);
|
||||
// TODO(nisse): What to do if creating the encoder fails? Crash,
|
||||
// or just discard incoming frames?
|
||||
RTC_CHECK(encoder_);
|
||||
|
Reference in New Issue
Block a user