Major AEC3 render pipeline changes

This CL adds major render pipeline changes to the AEC3 code. The reason
for these are that
1) It allows the echo removal unit to receive information about the content
in bands beyond band 0, thereby allowing removal of high-frequency
echoes
2) It allows more controlled handling of the render buffers, allowing proper
buffer behaviour during capture glitches and clock-drift.

Unfortunately, the render pipeline caused a lot of related changes in much
of the rest of the AEC3 files. Most of these are, however, caused by
a change of class name.

Another unfortunate effect of this CL, is that a number of unittest cease to
compile. I chose to temporarily solve that by removing them from the
build using #if/#endif. The reason for that is that those will anyway again
need to be changed in the next review, and doing like this avoids them
having to be reviewed twice.

BUG=webrtc:6018

Review-Url: https://codereview.webrtc.org/2784023002
Cr-Commit-Position: refs/heads/master@{#17547}
This commit is contained in:
peah
2017-04-05 14:18:07 -07:00
committed by Commit bot
parent 4aceaf268e
commit cf02cf13a7
67 changed files with 995 additions and 1099 deletions

View File

@ -569,7 +569,8 @@ int AudioProcessingImpl::InitializeLocked(const ProcessingConfig& config) {
submodule_states_.RenderMultiBandSubModulesActive());
// TODO(aluebs): Remove this restriction once we figure out why the 3-band
// splitting filter degrades the AEC performance.
if (render_processing_rate > kSampleRate32kHz) {
if (render_processing_rate > kSampleRate32kHz &&
!config_.echo_canceller3.enabled) {
render_processing_rate = submodule_states_.RenderMultiBandProcessingActive()
? kSampleRate32kHz
: kSampleRate16kHz;
@ -1440,9 +1441,7 @@ int AudioProcessingImpl::ProcessRenderStreamLocked() {
QueueRenderAudio(render_buffer);
// TODO(peah): Perform the queueing ínside QueueRenderAudiuo().
if (private_submodules_->echo_canceller3) {
if (!private_submodules_->echo_canceller3->AnalyzeRender(render_buffer)) {
// TODO(peah): Lock and empty render queue, and try again.
}
private_submodules_->echo_canceller3->AnalyzeRender(render_buffer);
}
if (submodule_states_.RenderMultiBandProcessingActive() &&