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

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

Issue 1983843002: Add aec-refined-adaptive-filter command line switch (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2661
Patch Set: Created 4 years, 7 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 3e529a83e1752a21e826e3a430faf6dbe01bd2d8..4b28c7a1c7497c9ef97069c9aef214e6827a7670 100644
--- a/content/renderer/media/media_stream_audio_processor.cc
+++ b/content/renderer/media/media_stream_audio_processor.cc
@@ -117,6 +117,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(
+ switches::kAecRefinedAdaptiveFilter);
+}
+
} // namespace
// Wraps AudioBus to provide access to the array of channel pointers, since this
@@ -529,6 +536,10 @@ void MediaStreamAudioProcessor::InitializeAudioProcessingModule(
new webrtc::ExperimentalNs(goog_experimental_ns));
if (IsDelayAgnosticAecEnabled())
config.Set<webrtc::DelayAgnostic>(new webrtc::DelayAgnostic(true));
+ if (UseAecRefinedAdaptiveFilter()) {
+ config.Set<webrtc::RefinedAdaptiveFilter>(
+ new webrtc::RefinedAdaptiveFilter(true));
+ }
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