| Index: webrtc/voice_engine/channel.cc
|
| diff --git a/webrtc/voice_engine/channel.cc b/webrtc/voice_engine/channel.cc
|
| index 90478564f796ef24e16c4755527652395e60bd0c..37ddd162e56c0c062e7ab2ae08416128d8374fc7 100644
|
| --- a/webrtc/voice_engine/channel.cc
|
| +++ b/webrtc/voice_engine/channel.cc
|
| @@ -662,11 +662,23 @@ int32_t Channel::CreateChannel(Channel*& channel,
|
| uint32_t instanceId,
|
| RtcEventLog* const event_log,
|
| const Config& config) {
|
| + return CreateChannel(channel, channelId, instanceId, event_log, config,
|
| + CreateBuiltinAudioDecoderFactory());
|
| +}
|
| +
|
| +int32_t Channel::CreateChannel(
|
| + Channel*& channel,
|
| + int32_t channelId,
|
| + uint32_t instanceId,
|
| + RtcEventLog* const event_log,
|
| + const Config& config,
|
| + const rtc::scoped_refptr<AudioDecoderFactory>& decoder_factory) {
|
| WEBRTC_TRACE(kTraceMemory, kTraceVoice, VoEId(instanceId, channelId),
|
| "Channel::CreateChannel(channelId=%d, instanceId=%d)", channelId,
|
| instanceId);
|
|
|
| - channel = new Channel(channelId, instanceId, event_log, config);
|
| + channel =
|
| + new Channel(channelId, instanceId, event_log, config, decoder_factory);
|
| if (channel == NULL) {
|
| WEBRTC_TRACE(kTraceMemory, kTraceVoice, VoEId(instanceId, channelId),
|
| "Channel::CreateChannel() unable to allocate memory for"
|
| @@ -726,7 +738,8 @@ void Channel::RecordFileEnded(int32_t id) {
|
| Channel::Channel(int32_t channelId,
|
| uint32_t instanceId,
|
| RtcEventLog* const event_log,
|
| - const Config& config)
|
| + const Config& config,
|
| + const rtc::scoped_refptr<AudioDecoderFactory>& decoder_factory)
|
| : _instanceId(instanceId),
|
| _channelId(channelId),
|
| event_log_(event_log),
|
| @@ -815,7 +828,7 @@ Channel::Channel(int32_t channelId,
|
| acm_config.neteq_config.enable_fast_accelerate =
|
| config.Get<NetEqFastAccelerate>().enabled;
|
| acm_config.neteq_config.enable_muted_state = false;
|
| - acm_config.decoder_factory = CreateBuiltinAudioDecoderFactory();
|
| + acm_config.decoder_factory = decoder_factory;
|
| audio_coding_.reset(AudioCodingModule::Create(acm_config));
|
|
|
| _outputAudioLevel.Clear();
|
|
|