blob: 5f4f98a78f0cf748e21fb0c3a91a127b949c1793 [file] [log] [blame]
solenberg13725082015-11-25 08:16:52 -08001/*
2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved.
3 *
4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
9 */
10
11#include "webrtc/voice_engine/channel_proxy.h"
12
Tommif888bb52015-12-12 01:37:01 +010013#include <utility>
14
kjellandera69d9732016-08-31 07:33:05 -070015#include "webrtc/api/call/audio_sink.h"
nissecae45d02017-04-24 05:53:20 -070016#include "webrtc/call/rtp_transport_controller_send_interface.h"
Edward Lemurc20978e2017-07-06 19:44:34 +020017#include "webrtc/rtc_base/checks.h"
18#include "webrtc/rtc_base/logging.h"
19#include "webrtc/rtc_base/safe_minmax.h"
solenberg13725082015-11-25 08:16:52 -080020#include "webrtc/voice_engine/channel.h"
21
22namespace webrtc {
23namespace voe {
24ChannelProxy::ChannelProxy() : channel_owner_(nullptr) {}
25
26ChannelProxy::ChannelProxy(const ChannelOwner& channel_owner) :
27 channel_owner_(channel_owner) {
28 RTC_CHECK(channel_owner_.channel());
solenberg08b19df2017-02-15 00:42:31 -080029 module_process_thread_checker_.DetachFromThread();
solenberg13725082015-11-25 08:16:52 -080030}
31
Tommif888bb52015-12-12 01:37:01 +010032ChannelProxy::~ChannelProxy() {}
33
ossu1ffbd6c2017-04-06 12:05:04 -070034bool ChannelProxy::SetEncoder(int payload_type,
35 std::unique_ptr<AudioEncoder> encoder) {
36 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
37 return channel()->SetEncoder(payload_type, std::move(encoder));
38}
39
ossu20a4b3f2017-04-27 02:08:52 -070040void ChannelProxy::ModifyEncoder(
41 rtc::FunctionView<void(std::unique_ptr<AudioEncoder>*)> modifier) {
42 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
43 channel()->ModifyEncoder(modifier);
44}
45
solenberg13725082015-11-25 08:16:52 -080046void ChannelProxy::SetRTCPStatus(bool enable) {
solenberg08b19df2017-02-15 00:42:31 -080047 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg358057b2015-11-27 10:46:42 -080048 channel()->SetRTCPStatus(enable);
solenberg13725082015-11-25 08:16:52 -080049}
50
51void ChannelProxy::SetLocalSSRC(uint32_t ssrc) {
solenberg08b19df2017-02-15 00:42:31 -080052 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg358057b2015-11-27 10:46:42 -080053 int error = channel()->SetLocalSSRC(ssrc);
solenberg13725082015-11-25 08:16:52 -080054 RTC_DCHECK_EQ(0, error);
55}
56
57void ChannelProxy::SetRTCP_CNAME(const std::string& c_name) {
solenberg08b19df2017-02-15 00:42:31 -080058 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg13725082015-11-25 08:16:52 -080059 // Note: VoERTP_RTCP::SetRTCP_CNAME() accepts a char[256] array.
60 std::string c_name_limited = c_name.substr(0, 255);
solenberg358057b2015-11-27 10:46:42 -080061 int error = channel()->SetRTCP_CNAME(c_name_limited.c_str());
solenberg13725082015-11-25 08:16:52 -080062 RTC_DCHECK_EQ(0, error);
63}
solenberg358057b2015-11-27 10:46:42 -080064
solenberg971cab02016-06-14 10:02:41 -070065void ChannelProxy::SetNACKStatus(bool enable, int max_packets) {
solenberg08b19df2017-02-15 00:42:31 -080066 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg971cab02016-06-14 10:02:41 -070067 channel()->SetNACKStatus(enable, max_packets);
68}
69
solenberg358057b2015-11-27 10:46:42 -080070void ChannelProxy::SetSendAudioLevelIndicationStatus(bool enable, int id) {
solenberg08b19df2017-02-15 00:42:31 -080071 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg358057b2015-11-27 10:46:42 -080072 int error = channel()->SetSendAudioLevelIndicationStatus(enable, id);
73 RTC_DCHECK_EQ(0, error);
74}
75
solenberg358057b2015-11-27 10:46:42 -080076void ChannelProxy::SetReceiveAudioLevelIndicationStatus(bool enable, int id) {
solenberg08b19df2017-02-15 00:42:31 -080077 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg358057b2015-11-27 10:46:42 -080078 int error = channel()->SetReceiveAudioLevelIndicationStatus(enable, id);
79 RTC_DCHECK_EQ(0, error);
80}
81
stefan3313ec92016-01-21 06:32:43 -080082void ChannelProxy::EnableSendTransportSequenceNumber(int id) {
solenberg08b19df2017-02-15 00:42:31 -080083 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
stefan3313ec92016-01-21 06:32:43 -080084 channel()->EnableSendTransportSequenceNumber(id);
85}
86
87void ChannelProxy::EnableReceiveTransportSequenceNumber(int id) {
solenberg08b19df2017-02-15 00:42:31 -080088 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
stefan3313ec92016-01-21 06:32:43 -080089 channel()->EnableReceiveTransportSequenceNumber(id);
90}
91
stefanbba9dec2016-02-01 04:39:55 -080092void ChannelProxy::RegisterSenderCongestionControlObjects(
nisseb8f9a322017-03-27 05:36:15 -070093 RtpTransportControllerSendInterface* transport,
stefan7de8d642017-02-07 07:14:08 -080094 RtcpBandwidthObserver* bandwidth_observer) {
solenberg08b19df2017-02-15 00:42:31 -080095 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
nisseb8f9a322017-03-27 05:36:15 -070096 channel()->RegisterSenderCongestionControlObjects(transport,
97 bandwidth_observer);
Stefan Holmerb86d4e42015-12-07 10:26:18 +010098}
99
stefanbba9dec2016-02-01 04:39:55 -0800100void ChannelProxy::RegisterReceiverCongestionControlObjects(
101 PacketRouter* packet_router) {
solenberg08b19df2017-02-15 00:42:31 -0800102 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
stefanbba9dec2016-02-01 04:39:55 -0800103 channel()->RegisterReceiverCongestionControlObjects(packet_router);
104}
105
nissefdbfdc92017-03-31 05:44:52 -0700106void ChannelProxy::ResetSenderCongestionControlObjects() {
solenberg08b19df2017-02-15 00:42:31 -0800107 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
nissefdbfdc92017-03-31 05:44:52 -0700108 channel()->ResetSenderCongestionControlObjects();
109}
110
111void ChannelProxy::ResetReceiverCongestionControlObjects() {
112 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
113 channel()->ResetReceiverCongestionControlObjects();
stefanbba9dec2016-02-01 04:39:55 -0800114}
115
solenberg358057b2015-11-27 10:46:42 -0800116CallStatistics ChannelProxy::GetRTCPStatistics() const {
solenberg08b19df2017-02-15 00:42:31 -0800117 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg358057b2015-11-27 10:46:42 -0800118 CallStatistics stats = {0};
119 int error = channel()->GetRTPStatistics(stats);
120 RTC_DCHECK_EQ(0, error);
121 return stats;
122}
123
124std::vector<ReportBlock> ChannelProxy::GetRemoteRTCPReportBlocks() const {
solenberg08b19df2017-02-15 00:42:31 -0800125 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg358057b2015-11-27 10:46:42 -0800126 std::vector<webrtc::ReportBlock> blocks;
127 int error = channel()->GetRemoteRTCPReportBlocks(&blocks);
128 RTC_DCHECK_EQ(0, error);
129 return blocks;
130}
131
132NetworkStatistics ChannelProxy::GetNetworkStatistics() const {
solenberg08b19df2017-02-15 00:42:31 -0800133 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg358057b2015-11-27 10:46:42 -0800134 NetworkStatistics stats = {0};
135 int error = channel()->GetNetworkStatistics(stats);
136 RTC_DCHECK_EQ(0, error);
137 return stats;
138}
139
140AudioDecodingCallStats ChannelProxy::GetDecodingCallStatistics() const {
solenberg08b19df2017-02-15 00:42:31 -0800141 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg358057b2015-11-27 10:46:42 -0800142 AudioDecodingCallStats stats;
143 channel()->GetDecodingCallStatistics(&stats);
144 return stats;
145}
146
ivoce1198e02017-09-08 08:13:19 -0700147ANAStats ChannelProxy::GetANAStatistics() const {
148 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
149 return channel()->GetANAStatistics();
150}
151
solenberg8d73f8c2017-03-08 01:52:20 -0800152int ChannelProxy::GetSpeechOutputLevel() const {
solenberg796b8f92017-03-01 17:02:23 -0800153 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg8d73f8c2017-03-08 01:52:20 -0800154 return channel()->GetSpeechOutputLevel();
solenberg796b8f92017-03-01 17:02:23 -0800155}
156
solenberg8d73f8c2017-03-08 01:52:20 -0800157int ChannelProxy::GetSpeechOutputLevelFullRange() const {
solenberg08b19df2017-02-15 00:42:31 -0800158 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg8d73f8c2017-03-08 01:52:20 -0800159 return channel()->GetSpeechOutputLevelFullRange();
solenberg358057b2015-11-27 10:46:42 -0800160}
161
zsteine76bd3a2017-07-14 12:17:49 -0700162double ChannelProxy::GetTotalOutputEnergy() const {
163 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
164 return channel()->GetTotalOutputEnergy();
165}
166
167double ChannelProxy::GetTotalOutputDuration() const {
168 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
169 return channel()->GetTotalOutputDuration();
170}
171
solenberg358057b2015-11-27 10:46:42 -0800172uint32_t ChannelProxy::GetDelayEstimate() const {
solenberg08b19df2017-02-15 00:42:31 -0800173 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread() ||
174 module_process_thread_checker_.CalledOnValidThread());
solenberg358057b2015-11-27 10:46:42 -0800175 return channel()->GetDelayEstimate();
176}
177
solenbergffbbcac2016-11-17 05:25:37 -0800178bool ChannelProxy::SetSendTelephoneEventPayloadType(int payload_type,
179 int payload_frequency) {
solenberg08b19df2017-02-15 00:42:31 -0800180 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenbergffbbcac2016-11-17 05:25:37 -0800181 return channel()->SetSendTelephoneEventPayloadType(payload_type,
182 payload_frequency) == 0;
Fredrik Solenbergb5727682015-12-04 15:22:19 +0100183}
184
solenberg8842c3e2016-03-11 03:06:41 -0800185bool ChannelProxy::SendTelephoneEventOutband(int event, int duration_ms) {
solenberg08b19df2017-02-15 00:42:31 -0800186 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg8842c3e2016-03-11 03:06:41 -0800187 return channel()->SendTelephoneEventOutband(event, duration_ms) == 0;
Fredrik Solenbergb5727682015-12-04 15:22:19 +0100188}
189
minyue78b4d562016-11-30 04:47:39 -0800190void ChannelProxy::SetBitrate(int bitrate_bps, int64_t probing_interval_ms) {
tommi0f8b4032017-02-22 11:22:05 -0800191 // This method can be called on the worker thread, module process thread
192 // or on a TaskQueue via VideoSendStreamImpl::OnEncoderConfigurationChanged.
193 // TODO(solenberg): Figure out a good way to check this or enforce calling
194 // rules.
195 // RTC_DCHECK(worker_thread_checker_.CalledOnValidThread() ||
196 // module_process_thread_checker_.CalledOnValidThread());
minyue78b4d562016-11-30 04:47:39 -0800197 channel()->SetBitRate(bitrate_bps, probing_interval_ms);
mflodman86cc6ff2016-07-26 04:44:06 -0700198}
199
kwibergd32bf752017-01-19 07:03:59 -0800200void ChannelProxy::SetRecPayloadType(int payload_type,
201 const SdpAudioFormat& format) {
solenberg08b19df2017-02-15 00:42:31 -0800202 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
kwibergd32bf752017-01-19 07:03:59 -0800203 const int result = channel()->SetRecPayloadType(payload_type, format);
204 RTC_DCHECK_EQ(0, result);
205}
206
kwiberg1c07c702017-03-27 07:15:49 -0700207void ChannelProxy::SetReceiveCodecs(
208 const std::map<int, SdpAudioFormat>& codecs) {
209 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
210 channel()->SetReceiveCodecs(codecs);
211}
212
kwibergb7f89d62016-02-17 10:04:18 -0800213void ChannelProxy::SetSink(std::unique_ptr<AudioSinkInterface> sink) {
solenberg08b19df2017-02-15 00:42:31 -0800214 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
deadbeef2d110be2016-01-13 12:00:26 -0800215 channel()->SetSink(std::move(sink));
Tommif888bb52015-12-12 01:37:01 +0100216}
217
solenberg94218532016-06-16 10:53:22 -0700218void ChannelProxy::SetInputMute(bool muted) {
solenberg08b19df2017-02-15 00:42:31 -0800219 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg8d73f8c2017-03-08 01:52:20 -0800220 channel()->SetInputMute(muted);
solenberg94218532016-06-16 10:53:22 -0700221}
222
mflodman3d7db262016-04-29 00:57:13 -0700223void ChannelProxy::RegisterExternalTransport(Transport* transport) {
solenberg08b19df2017-02-15 00:42:31 -0800224 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
mflodman3d7db262016-04-29 00:57:13 -0700225 int error = channel()->RegisterExternalTransport(transport);
226 RTC_DCHECK_EQ(0, error);
227}
228
229void ChannelProxy::DeRegisterExternalTransport() {
solenberg08b19df2017-02-15 00:42:31 -0800230 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
mflodman3d7db262016-04-29 00:57:13 -0700231 channel()->DeRegisterExternalTransport();
232}
233
nisse657bab22017-02-21 06:28:10 -0800234void ChannelProxy::OnRtpPacket(const RtpPacketReceived& packet) {
mflodman3d7db262016-04-29 00:57:13 -0700235 // May be called on either worker thread or network thread.
nisse657bab22017-02-21 06:28:10 -0800236 channel()->OnRtpPacket(packet);
mflodman3d7db262016-04-29 00:57:13 -0700237}
238
239bool ChannelProxy::ReceivedRTCPPacket(const uint8_t* packet, size_t length) {
240 // May be called on either worker thread or network thread.
241 return channel()->ReceivedRTCPPacket(packet, length) == 0;
242}
243
ossu29b1a8d2016-06-13 07:34:51 -0700244const rtc::scoped_refptr<AudioDecoderFactory>&
solenberg217fb662016-06-17 08:30:54 -0700245 ChannelProxy::GetAudioDecoderFactory() const {
solenberg08b19df2017-02-15 00:42:31 -0800246 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
ossu29b1a8d2016-06-13 07:34:51 -0700247 return channel()->GetAudioDecoderFactory();
248}
249
solenberg217fb662016-06-17 08:30:54 -0700250void ChannelProxy::SetChannelOutputVolumeScaling(float scaling) {
solenberg08b19df2017-02-15 00:42:31 -0800251 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg8d73f8c2017-03-08 01:52:20 -0800252 channel()->SetChannelOutputVolumeScaling(scaling);
solenberg217fb662016-06-17 08:30:54 -0700253}
254
ivoc14d5dbe2016-07-04 07:06:55 -0700255void ChannelProxy::SetRtcEventLog(RtcEventLog* event_log) {
solenberg08b19df2017-02-15 00:42:31 -0800256 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
ivoc14d5dbe2016-07-04 07:06:55 -0700257 channel()->SetRtcEventLog(event_log);
258}
259
aleloi6c278492016-10-20 14:24:39 -0700260AudioMixer::Source::AudioFrameInfo ChannelProxy::GetAudioFrameWithInfo(
261 int sample_rate_hz,
262 AudioFrame* audio_frame) {
solenberg08b19df2017-02-15 00:42:31 -0800263 RTC_DCHECK_RUNS_SERIALIZED(&audio_thread_race_checker_);
aleloi6c278492016-10-20 14:24:39 -0700264 return channel()->GetAudioFrameWithInfo(sample_rate_hz, audio_frame);
aleloiaed581a2016-10-20 06:32:39 -0700265}
266
aleloi051f6782016-10-31 03:26:40 -0700267int ChannelProxy::NeededFrequency() const {
solenberg08b19df2017-02-15 00:42:31 -0800268 RTC_DCHECK_RUNS_SERIALIZED(&audio_thread_race_checker_);
aleloi051f6782016-10-31 03:26:40 -0700269 return static_cast<int>(channel()->NeededFrequency(-1));
270}
271
michaelt79e05882016-11-08 02:50:09 -0800272void ChannelProxy::SetTransportOverhead(int transport_overhead_per_packet) {
solenberg08b19df2017-02-15 00:42:31 -0800273 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
michaelt79e05882016-11-08 02:50:09 -0800274 channel()->SetTransportOverhead(transport_overhead_per_packet);
275}
276
solenberg7602aab2016-11-14 11:30:07 -0800277void ChannelProxy::AssociateSendChannel(
278 const ChannelProxy& send_channel_proxy) {
solenberg08b19df2017-02-15 00:42:31 -0800279 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg7602aab2016-11-14 11:30:07 -0800280 channel()->set_associate_send_channel(send_channel_proxy.channel_owner_);
281}
282
283void ChannelProxy::DisassociateSendChannel() {
solenberg08b19df2017-02-15 00:42:31 -0800284 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenberg7602aab2016-11-14 11:30:07 -0800285 channel()->set_associate_send_channel(ChannelOwner(nullptr));
286}
287
solenberg3ebbcb52017-01-31 03:58:40 -0800288void ChannelProxy::GetRtpRtcp(RtpRtcp** rtp_rtcp,
289 RtpReceiver** rtp_receiver) const {
solenberg08b19df2017-02-15 00:42:31 -0800290 RTC_DCHECK(module_process_thread_checker_.CalledOnValidThread());
solenberg3ebbcb52017-01-31 03:58:40 -0800291 RTC_DCHECK(rtp_rtcp);
292 RTC_DCHECK(rtp_receiver);
293 int error = channel()->GetRtpRtcp(rtp_rtcp, rtp_receiver);
294 RTC_DCHECK_EQ(0, error);
295}
296
solenberg3ebbcb52017-01-31 03:58:40 -0800297uint32_t ChannelProxy::GetPlayoutTimestamp() const {
solenberg08b19df2017-02-15 00:42:31 -0800298 RTC_DCHECK_RUNS_SERIALIZED(&video_capture_thread_race_checker_);
solenberg3ebbcb52017-01-31 03:58:40 -0800299 unsigned int timestamp = 0;
300 int error = channel()->GetPlayoutTimestamp(timestamp);
301 RTC_DCHECK(!error || timestamp == 0);
302 return timestamp;
303}
304
305void ChannelProxy::SetMinimumPlayoutDelay(int delay_ms) {
solenberg08b19df2017-02-15 00:42:31 -0800306 RTC_DCHECK(module_process_thread_checker_.CalledOnValidThread());
solenberg3ebbcb52017-01-31 03:58:40 -0800307 // Limit to range accepted by both VoE and ACM, so we're at least getting as
308 // close as possible, instead of failing.
kwiberg07038562017-06-12 11:40:47 -0700309 delay_ms = rtc::SafeClamp(delay_ms, 0, 10000);
solenberg3ebbcb52017-01-31 03:58:40 -0800310 int error = channel()->SetMinimumPlayoutDelay(delay_ms);
solenberg0335e6c2017-02-22 07:07:04 -0800311 if (0 != error) {
312 LOG(LS_WARNING) << "Error setting minimum playout delay.";
313 }
solenberg3ebbcb52017-01-31 03:58:40 -0800314}
315
michaelt9332b7d2016-11-30 07:51:13 -0800316void ChannelProxy::SetRtcpRttStats(RtcpRttStats* rtcp_rtt_stats) {
solenberg08b19df2017-02-15 00:42:31 -0800317 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
michaelt9332b7d2016-11-30 07:51:13 -0800318 channel()->SetRtcpRttStats(rtcp_rtt_stats);
319}
320
solenbergbd9a77f2017-02-06 12:53:57 -0800321bool ChannelProxy::GetRecCodec(CodecInst* codec_inst) const {
solenberg08b19df2017-02-15 00:42:31 -0800322 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
solenbergbd9a77f2017-02-06 12:53:57 -0800323 return channel()->GetRecCodec(*codec_inst) == 0;
324}
325
elad.alond12a8e12017-03-23 11:04:48 -0700326void ChannelProxy::OnTwccBasedUplinkPacketLossRate(float packet_loss_rate) {
eladalon27e812e2017-08-25 01:50:58 -0700327 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
elad.alond12a8e12017-03-23 11:04:48 -0700328 channel()->OnTwccBasedUplinkPacketLossRate(packet_loss_rate);
329}
330
elad.alondadb4dc2017-03-23 15:29:50 -0700331void ChannelProxy::OnRecoverableUplinkPacketLossRate(
332 float recoverable_packet_loss_rate) {
eladalon27e812e2017-08-25 01:50:58 -0700333 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
elad.alondadb4dc2017-03-23 15:29:50 -0700334 channel()->OnRecoverableUplinkPacketLossRate(recoverable_packet_loss_rate);
335}
336
kwiberg1c07c702017-03-27 07:15:49 -0700337void ChannelProxy::RegisterLegacyReceiveCodecs() {
338 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
339 channel()->RegisterLegacyReceiveCodecs();
340}
341
hbos8d609f62017-04-10 07:39:05 -0700342std::vector<RtpSource> ChannelProxy::GetSources() const {
343 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
344 return channel()->GetSources();
345}
346
solenberg358057b2015-11-27 10:46:42 -0800347Channel* ChannelProxy::channel() const {
348 RTC_DCHECK(channel_owner_.channel());
349 return channel_owner_.channel();
350}
Stefan Holmerb86d4e42015-12-07 10:26:18 +0100351
solenberg13725082015-11-25 08:16:52 -0800352} // namespace voe
353} // namespace webrtc