Here is the sequence of operations to be used for Webrtc_AGC:
- Create AGC:
WebRtcAgc_Create - Initialize AGC:
WebRtcAgc_Init - Set Config:
WebRtcAgc_set_config - Initialize
capture_level = 0 - For
kAgcModeAdaptiveDigital, invoke VirtualMic:WebRtcAgc_VirtualMic - Process Buffer with
capture_level:WebRtcAgc_Process - Get the out capture level returned from
WebRtcAgc_Processand set it tocapture_level - Repeat 5 to 7 for the
audio buffers - Destroy the AGC:
WebRtcAgc_Free
Check webrtc/modules/audio_processing/gain_control_impl.cc for reference.