r4326 was mistakenly committed to stable, so this is to re-merge back to trunk.
Fixed the AGC and interface problems on the new path.
In order to make the AGC work properly, we need to cache the volume value passed
by the callback, compare it with the value returned by
shared->transmit_mixer()->CaptureLevel(). If they are the same, we need to
return 0 to indicate no volume needs changing, otherwise return the new volume.
By doing this, we avoid setting the volume all the same, which allows the users
to change the volume manually.
This patch also fixes some minor issues with the interfaces too: make the int
channel[] const, and correct the order of the input params in
channel::Demultiplex.
R=tommi@webrtc.org
BUG=[2134]
TEST=compile && manual AGC test
Review URL: https://webrtc-codereview.appspot.com/1921004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@4450 4adac7df-926f-26a2-2b94-8c16560cd09d
r4326 was mistakenly committed to stable, so this is to re-merge back to trunk.
Add new interface to support multiple sources in webrtc.
CaptureData() will be called by chrome with a flag |need_audio_processing| to
indicate if the data needs to be processed by APM or not. Different from the old
interface that will send the data to all voe channels, the new interface will
specify a list of voe channels that the data is demultiplexing to.
R=tommi@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/1919004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@4449 4adac7df-926f-26a2-2b94-8c16560cd09d