An AGC example that applies the audio processing to the mic input and outputs the result to the speaker.
In this example, we update the gain value only when voice is detected in an input audio frame
to prevent amplifying background noises.
To detect voice, rnnoise-wasm library is used.
NOTE: This example only supports Chromium-based browsers such as Chrome and Edge.