Revert "Deprecate the adaptive level controller"
This reverts commit 6f37ed78d99daa36e964ff0a65b205f0916d9949.
Reason for revert: <INSERT REASONING HERE>
Original change's description:
> Deprecate the adaptive level controller
>
> Level control handled by default-on AGC.
>
> Bug: none
> Change-Id: I405daeceece12c896d41156b649fcfd556726f77
> Reviewed-on: https://webrtc-review.googlesource.com/59682
> Reviewed-by: Fredrik Solenberg <solenberg@webrtc.org>
> Reviewed-by: Alex Loiko <aleloi@webrtc.org>
> Commit-Queue: Sam Zackrisson <saza@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#22305}
TBR=solenberg@webrtc.org,saza@webrtc.org,aleloi@webrtc.org
Change-Id: Ic52f41fcbebfd2291a51b17ac788313e1ceef163
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: none
Reviewed-on: https://webrtc-review.googlesource.com/60240
Reviewed-by: Sam Zackrisson <saza@webrtc.org>
Commit-Queue: Sam Zackrisson <saza@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22308}
diff --git a/modules/audio_processing/include/audio_processing.h b/modules/audio_processing/include/audio_processing.h
index 33ecf89..7057f28 100644
--- a/modules/audio_processing/include/audio_processing.h
+++ b/modules/audio_processing/include/audio_processing.h
@@ -211,8 +211,8 @@
// AudioProcessing* apm = AudioProcessingBuilder().Create();
//
// AudioProcessing::Config config;
+// config.level_controller.enabled = true;
// config.high_pass_filter.enabled = true;
-// config.gain_controller2.enabled = true;
// apm->ApplyConfig(config)
//
// apm->echo_cancellation()->enable_drift_compensation(false);
@@ -262,6 +262,14 @@
// by changing the default values in the AudioProcessing::Config struct.
// The config is applied by passing the struct to the ApplyConfig method.
struct Config {
+ struct LevelController {
+ bool enabled = false;
+
+ // Sets the initial peak level to use inside the level controller in order
+ // to compute the signal gain. The unit for the peak level is dBFS and
+ // the allowed range is [-100, 0].
+ float initial_peak_level_dbfs = -6.0206f;
+ } level_controller;
struct ResidualEchoDetector {
bool enabled = true;
} residual_echo_detector;