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

Unified Diff: webrtc/modules/audio_processing/aec3/echo_canceller3.cc

Issue 2611223003: Adding second layer of the echo canceller 3 functionality. (Closed)
Patch Set: Created 3 years, 11 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
Index: webrtc/modules/audio_processing/aec3/echo_canceller3.cc
diff --git a/webrtc/modules/audio_processing/aec3/echo_canceller3.cc b/webrtc/modules/audio_processing/aec3/echo_canceller3.cc
index b409e60350e2c2b6c45b2395d8a42d6285f92410..c360de48c11b35b38e4a28755b4ba02777397ec1 100644
--- a/webrtc/modules/audio_processing/aec3/echo_canceller3.cc
+++ b/webrtc/modules/audio_processing/aec3/echo_canceller3.cc
@@ -53,7 +53,7 @@ void FillSubFrameView(std::vector<std::vector<float>>* frame,
void ProcessCaptureFrameContent(
AudioBuffer* capture,
- bool known_echo_path_change,
+ bool level_change,
bool saturated_microphone_signal,
size_t sub_frame_index,
FrameBlocker* capture_blocker,
@@ -63,13 +63,13 @@ void ProcessCaptureFrameContent(
std::vector<rtc::ArrayView<float>>* sub_frame_view) {
FillSubFrameView(capture, sub_frame_index, sub_frame_view);
capture_blocker->InsertSubFrameAndExtractBlock(*sub_frame_view, block);
- block_processor->ProcessCapture(known_echo_path_change,
- saturated_microphone_signal, block);
+ block_processor->ProcessCapture(level_change, saturated_microphone_signal,
+ block);
output_framer->InsertBlockAndExtractSubFrame(*block, sub_frame_view);
}
void ProcessRemainingCaptureFrameContent(
- bool known_echo_path_change,
+ bool level_change,
bool saturated_microphone_signal,
FrameBlocker* capture_blocker,
BlockFramer* output_framer,
@@ -80,8 +80,8 @@ void ProcessRemainingCaptureFrameContent(
}
capture_blocker->ExtractBlock(block);
- block_processor->ProcessCapture(known_echo_path_change,
- saturated_microphone_signal, block);
+ block_processor->ProcessCapture(level_change, saturated_microphone_signal,
+ block);
output_framer->InsertBlock(*block);
}
@@ -275,8 +275,7 @@ void EchoCanceller3::AnalyzeCapture(AudioBuffer* capture) {
}
}
-void EchoCanceller3::ProcessCapture(AudioBuffer* capture,
- bool known_echo_path_change) {
+void EchoCanceller3::ProcessCapture(AudioBuffer* capture, bool level_change) {
RTC_DCHECK_RUNS_SERIALIZED(&capture_race_checker_);
RTC_DCHECK(capture);
RTC_DCHECK_EQ(1u, capture->num_channels());
@@ -296,20 +295,19 @@ void EchoCanceller3::ProcessCapture(AudioBuffer* capture,
capture_highpass_filter_->Process(capture_lower_band);
}
- ProcessCaptureFrameContent(capture, known_echo_path_change,
- saturated_microphone_signal_, 0, &capture_blocker_,
- &output_framer_, block_processor_.get(), &block_,
- &sub_frame_view_);
+ ProcessCaptureFrameContent(
+ capture, level_change, saturated_microphone_signal_, 0, &capture_blocker_,
+ &output_framer_, block_processor_.get(), &block_, &sub_frame_view_);
if (sample_rate_hz_ != 8000) {
ProcessCaptureFrameContent(
- capture, known_echo_path_change, saturated_microphone_signal_, 1,
+ capture, level_change, saturated_microphone_signal_, 1,
&capture_blocker_, &output_framer_, block_processor_.get(), &block_,
&sub_frame_view_);
}
ProcessRemainingCaptureFrameContent(
- known_echo_path_change, saturated_microphone_signal_, &capture_blocker_,
+ level_change, saturated_microphone_signal_, &capture_blocker_,
&output_framer_, block_processor_.get(), &block_);
data_dumper_->DumpWav("aec3_capture_output", frame_length_,

Powered by Google App Engine
This is Rietveld 408576698