Support external audio mixer in webrtc.

An external audio mixer will be passed from PeerConnectionFactory to
AudioTransportProxy.

BUG=webrtc:6457

Review-Url: https://codereview.webrtc.org/2539213003
Cr-Commit-Position: refs/heads/master@{#15556}
This commit is contained in:
gyzhou
2016-12-12 16:25:06 -08:00
committed by Commit bot
parent 1354901663
commit f6bcac59e8
13 changed files with 121 additions and 65 deletions

View File

@ -87,6 +87,7 @@ class WebRtcVideoEncoderFactory;
namespace webrtc {
class AudioDeviceModule;
class AudioMixer;
class MediaConstraintsInterface;
// MediaStream container interface.
@ -803,6 +804,20 @@ rtc::scoped_refptr<PeerConnectionFactoryInterface> CreatePeerConnectionFactory(
cricket::WebRtcVideoEncoderFactory* encoder_factory,
cricket::WebRtcVideoDecoderFactory* decoder_factory);
// Create a new instance of PeerConnectionFactoryInterface with external audio
// mixer.
//
// If |audio_mixer| is null, an internal audio mixer will be created and used.
rtc::scoped_refptr<PeerConnectionFactoryInterface>
CreatePeerConnectionFactoryWithAudioMixer(
rtc::Thread* network_thread,
rtc::Thread* worker_thread,
rtc::Thread* signaling_thread,
AudioDeviceModule* default_adm,
cricket::WebRtcVideoEncoderFactory* encoder_factory,
cricket::WebRtcVideoDecoderFactory* decoder_factory,
rtc::scoped_refptr<AudioMixer> audio_mixer);
// Create a new instance of PeerConnectionFactoryInterface.
// Same thread is used as worker and network thread.
inline rtc::scoped_refptr<PeerConnectionFactoryInterface>