Audio Processing Module (APM)
音频处理模块(APM)
Overview
概述
The APM is responsible for applying speech enhancements effects to the microphone signal. These effects are required for VoIP calling and some examples include echo cancellation (AEC), noise suppression (NS) and automatic gain control (AGC).
APM负责将语音增强效果应用于麦克风信号。VoIP呼叫需要这些效果,并且一些示例包括回声消除(AEC)、噪声抑制(NS)和自动增益控制(AGC)。
The API for APM resides in [/modules/audio_processing/include
][https://source.chromium.org/chromium/chromium/src/+/main:third_party/webrtc/modules/audio_processing/include]. APM is created using the [AudioProcessingBuilder
][https://source.chromium.org/chromium/chromium/src/+/main:third_party/webrtc/modules/audio_processing/include/audio_processing.h] builder that allows it to be customized and configured.
APM的API位于[/modules/audio_processing/include]中[https://source.chromium.org/chromium/chromium/src/+/main:third_party/webrtc/modules/audio_processing/include]。APM是使用[AudioProcessingBuilder]创建的[https://source.chromium.org/chromium/chromium/src/+/main:third_party/webrtc/modules/audio_processing/include/audio_processing.h]生成器,允许对其进行自定义和配置。
Some specific aspects of APM include that:
APM的一些具体方面包括:
- APM is fully thread-safe in that it can be accessed concurrently from different threads.
- APM是完全线程安全的,因为它可以从不同的线程并发访问。
- APM handles for any input sample rates < 384 kHz and achieves this by automatic reconfiguration whenever a new sample format is observed.
- APM处理<384 kHz的任何输入采样率,并通过在观察到新的采样格式时自动重新配置来实现这一点。
- APM handles any number of microphone channels and loudspeaker channels, with the same automatic reconfiguration as for the sample rates.
- APM处理任意数量的麦克风通道和扬声器通道,具有与采样率相同的自动重新配置。
APM can either be used as part of the WebRTC native pipeline, or standalone.
APM既可以作为WebRTC本机管道的一部分使用,也可以独立使用。