Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(482)

Unified Diff: content/renderer/media/media_stream_audio_processor.cc

Issue 1894963002: Add aec-refined-adaptive-filter command line switch (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/public/common/content_switches.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/media/media_stream_audio_processor.cc
diff --git a/content/renderer/media/media_stream_audio_processor.cc b/content/renderer/media/media_stream_audio_processor.cc
index 869e41670616676625bcd1c13c154da54d406906..23039de63c527bbc6d704f3489a0adcb08ba90bf 100644
--- a/content/renderer/media/media_stream_audio_processor.cc
+++ b/content/renderer/media/media_stream_audio_processor.cc
@@ -111,6 +111,13 @@ bool GetStartupMinVolumeForAgc(int* startup_min_volume) {
base::StringToInt(min_volume_str, startup_min_volume);
}
+// Checks if the AEC's refined adaptive filter tuning was enabled on the command
+// line.
+bool UseAecRefinedAdaptiveFilter() {
+ return base::CommandLine::ForCurrentProcess()->HasSwitch(
aluebs-chromium 2016/04/18 20:52:49 Just out of curiosity, does this kind of switches
hlundin-chromium 2016/04/19 06:13:35 The plan is to maybe run a Finch experiment, but n
aluebs-chromium 2016/04/19 16:20:51 Yes, that is what I thought. I was just curious :)
+ switches::kAecRefinedAdaptiveFilter);
+}
+
} // namespace
// Wraps AudioBus to provide access to the array of channel pointers, since this
@@ -516,6 +523,10 @@ void MediaStreamAudioProcessor::InitializeAudioProcessingModule(
config.Set<webrtc::ExperimentalNs>(
new webrtc::ExperimentalNs(goog_experimental_ns));
config.Set<webrtc::DelayAgnostic>(new webrtc::DelayAgnostic(true));
+ if (UseAecRefinedAdaptiveFilter()) {
+ config.Set<webrtc::RefinedAdaptiveFilter>(
+ new webrtc::RefinedAdaptiveFilter(true));
+ }
aluebs-chromium 2016/04/18 20:52:49 Do you want to rely on the default WebRTC behavior
hlundin-chromium 2016/04/19 06:13:35 Ack. I'm relying on the default behavior for now.
aluebs-chromium 2016/04/19 16:20:51 Ack
if (goog_beamforming) {
const auto& geometry =
GetArrayGeometryPreferringConstraints(audio_constraints, input_params);
« no previous file with comments | « content/public/common/content_switches.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698