diff options
Diffstat (limited to 'audio')
-rw-r--r-- | audio/audio_receive_stream.cc | 13 | ||||
-rw-r--r-- | audio/channel.cc | 7 | ||||
-rw-r--r-- | audio/channel.h | 3 |
3 files changed, 13 insertions, 10 deletions
diff --git a/audio/audio_receive_stream.cc b/audio/audio_receive_stream.cc index 8a1fbed7dc..00b745bdd5 100644 --- a/audio/audio_receive_stream.cc +++ b/audio/audio_receive_stream.cc @@ -70,13 +70,12 @@ std::unique_ptr<voe::ChannelProxy> CreateChannelAndProxy( RTC_DCHECK(audio_state); internal::AudioState* internal_audio_state = static_cast<internal::AudioState*>(audio_state); - return std::unique_ptr<voe::ChannelProxy>(new voe::ChannelProxy( - std::unique_ptr<voe::Channel>(new voe::Channel( - module_process_thread, - internal_audio_state->audio_device_module(), - config.jitter_buffer_max_packets, - config.jitter_buffer_fast_accelerate, - config.decoder_factory)))); + return std::unique_ptr<voe::ChannelProxy>( + new voe::ChannelProxy(std::unique_ptr<voe::Channel>(new voe::Channel( + module_process_thread, internal_audio_state->audio_device_module(), + config.jitter_buffer_max_packets, + config.jitter_buffer_fast_accelerate, config.decoder_factory, + config.codec_pair_id)))); } } // namespace diff --git a/audio/channel.cc b/audio/channel.cc index d50c161cf1..986476c91b 100644 --- a/audio/channel.cc +++ b/audio/channel.cc @@ -557,7 +557,8 @@ Channel::Channel(rtc::TaskQueue* encoder_queue, audio_device_module, 0, false, - rtc::scoped_refptr<AudioDecoderFactory>()) { + rtc::scoped_refptr<AudioDecoderFactory>(), + rtc::nullopt) { RTC_DCHECK(encoder_queue); encoder_queue_ = encoder_queue; } @@ -566,7 +567,8 @@ Channel::Channel(ProcessThread* module_process_thread, AudioDeviceModule* audio_device_module, size_t jitter_buffer_max_packets, bool jitter_buffer_fast_playout, - rtc::scoped_refptr<AudioDecoderFactory> decoder_factory) + rtc::scoped_refptr<AudioDecoderFactory> decoder_factory, + rtc::Optional<AudioCodecPairId> codec_pair_id) : event_log_proxy_(new RtcEventLogProxy()), rtcp_rtt_stats_proxy_(new RtcpRttStatsProxy()), rtp_payload_registry_(new RTPPayloadRegistry()), @@ -610,6 +612,7 @@ Channel::Channel(ProcessThread* module_process_thread, RTC_DCHECK(audio_device_module); AudioCodingModule::Config acm_config; acm_config.decoder_factory = decoder_factory; + acm_config.neteq_config.codec_pair_id = codec_pair_id; acm_config.neteq_config.max_packets_in_buffer = jitter_buffer_max_packets; acm_config.neteq_config.enable_fast_accelerate = jitter_buffer_fast_playout; acm_config.neteq_config.enable_muted_state = true; diff --git a/audio/channel.h b/audio/channel.h index e59cae11ad..9d5bfa4bac 100644 --- a/audio/channel.h +++ b/audio/channel.h @@ -157,7 +157,8 @@ class Channel AudioDeviceModule* audio_device_module, size_t jitter_buffer_max_packets, bool jitter_buffer_fast_playout, - rtc::scoped_refptr<AudioDecoderFactory> decoder_factory); + rtc::scoped_refptr<AudioDecoderFactory> decoder_factory, + rtc::Optional<AudioCodecPairId> codec_pair_id); virtual ~Channel(); void SetSink(AudioSinkInterface* sink); |