modules/audio_processing: Adds a config for reported delays
There are platforms and devices where the reported delays are untrusted and we currently solve that with an extended filter length and a slightly more conservative delay handling.
With this change we give the user the possibility to turn off reported system delay values completely.
- Includes new unit tests.
TESTED=trybots and manual testing
R=aluebs@webrtc.org, kwiberg@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/13629004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@6391 4adac7df-926f-26a2-2b94-8c16560cd09d
diff --git a/webrtc/modules/audio_processing/include/audio_processing.h b/webrtc/modules/audio_processing/include/audio_processing.h
index 15e01b9..77c3f3a 100644
--- a/webrtc/modules/audio_processing/include/audio_processing.h
+++ b/webrtc/modules/audio_processing/include/audio_processing.h
@@ -53,6 +53,18 @@
bool enabled;
};
+// Use to disable the reported system delays. By disabling the reported system
+// delays the echo cancellation algorithm assumes the process and reverse
+// streams to be aligned. This configuration only applies to EchoCancellation
+// and not EchoControlMobile and is set with AudioProcessing::SetExtraOptions().
+// Note that by disabling reported system delays the EchoCancellation may
+// regress in performance.
+struct ReportedDelay {
+ ReportedDelay() : enabled(true) {}
+ explicit ReportedDelay(bool enabled) : enabled(enabled) {}
+ bool enabled;
+};
+
// Must be provided through AudioProcessing::Create(Confg&). It will have no
// impact if used with AudioProcessing::SetExtraOptions().
struct ExperimentalAgc {