From b1facc1f7107d801ef92719fb13ae7bdd5537c41 Mon Sep 17 00:00:00 2001 From: Ivo Creusen Date: Thu, 12 Apr 2018 16:15:58 +0200 Subject: [PATCH] The initialization of the echo detector should always signal that the input audio is mono. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Since we always pass in the first audio channel, we should always pass 1 as the number of channels in the initialization function. Bug: webrtc:8732 Change-Id: I978edb125d7cc701a5e07193256327908be00560 Reviewed-on: https://webrtc-review.googlesource.com/69660 Commit-Queue: Ivo Creusen Reviewed-by: Per Ã…hgren Cr-Commit-Position: refs/heads/master@{#22885} --- modules/audio_processing/audio_processing_impl.cc | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/modules/audio_processing/audio_processing_impl.cc b/modules/audio_processing/audio_processing_impl.cc index 526d7d5974..ddea435e30 100644 --- a/modules/audio_processing/audio_processing_impl.cc +++ b/modules/audio_processing/audio_processing_impl.cc @@ -1866,9 +1866,8 @@ void AudioProcessingImpl::InitializePreAmplifier() { void AudioProcessingImpl::InitializeResidualEchoDetector() { RTC_DCHECK(private_submodules_->echo_detector); private_submodules_->echo_detector->Initialize( - proc_sample_rate_hz(), num_proc_channels(), - formats_.render_processing_format.sample_rate_hz(), - formats_.render_processing_format.num_channels()); + proc_sample_rate_hz(), 1, + formats_.render_processing_format.sample_rate_hz(), 1); } void AudioProcessingImpl::InitializePostProcessor() {