diff --git a/api/audio/echo_canceller3_config.h b/api/audio/echo_canceller3_config.h index e7376ed7bc..49bc895ff3 100644 --- a/api/audio/echo_canceller3_config.h +++ b/api/audio/echo_canceller3_config.h @@ -78,7 +78,7 @@ struct EchoCanceller3Config { float lf = 1.f; float mf = 1.f; float hf = 1.f; - float default_len = 0.88f; + float default_len = 0.83f; bool reverb_based_on_render = true; bool echo_can_saturate = true; bool bounded_erl = false; diff --git a/modules/audio_processing/aec3/echo_canceller3.cc b/modules/audio_processing/aec3/echo_canceller3.cc index e5219c72ab..b2f9229683 100644 --- a/modules/audio_processing/aec3/echo_canceller3.cc +++ b/modules/audio_processing/aec3/echo_canceller3.cc @@ -62,6 +62,10 @@ bool EnableUnityNonZeroRampupGain() { return field_trial::IsEnabled("WebRTC-Aec3EnableUnityNonZeroRampupGain"); } +bool EnableLongReverb() { + return field_trial::IsEnabled("WebRTC-Aec3ShortReverbKillSwitch"); +} + // Method for adjusting config parameter dependencies.. EchoCanceller3Config AdjustConfig(const EchoCanceller3Config& config) { EchoCanceller3Config adjusted_cfg = config; @@ -147,6 +151,10 @@ EchoCanceller3Config AdjustConfig(const EchoCanceller3Config& config) { adjusted_cfg.echo_removal_control.gain_rampup.first_non_zero_gain = 1.f; } + if (EnableLongReverb()) { + adjusted_cfg.ep_strength.default_len = 0.88f; + } + return adjusted_cfg; }