OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 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 | 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 | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
87 // TODO(ossu): This is where we'd like to set the decoder factory to | 87 // TODO(ossu): This is where we'd like to set the decoder factory to |
88 // use. However, since it needs to be included when constructing Channel, we | 88 // use. However, since it needs to be included when constructing Channel, we |
89 // cannot do that until we're able to move Channel ownership into the | 89 // cannot do that until we're able to move Channel ownership into the |
90 // Audio{Send,Receive}Streams. The best we can do is check that we're not | 90 // Audio{Send,Receive}Streams. The best we can do is check that we're not |
91 // trying to use two different factories using the different interfaces. | 91 // trying to use two different factories using the different interfaces. |
92 RTC_CHECK(config.decoder_factory); | 92 RTC_CHECK(config.decoder_factory); |
93 RTC_CHECK_EQ(config.decoder_factory, | 93 RTC_CHECK_EQ(config.decoder_factory, |
94 channel_proxy_->GetAudioDecoderFactory()); | 94 channel_proxy_->GetAudioDecoderFactory()); |
95 | 95 |
96 channel_proxy_->RegisterExternalTransport(config.rtcp_send_transport); | 96 channel_proxy_->RegisterExternalTransport(config.rtcp_send_transport); |
97 | 97 channel_proxy_->SetReceiveCodecs(config.decoder_map); |
98 for (const auto& kv : config.decoder_map) { | |
99 channel_proxy_->SetRecPayloadType(kv.first, kv.second); | |
100 } | |
101 | 98 |
102 for (const auto& extension : config.rtp.extensions) { | 99 for (const auto& extension : config.rtp.extensions) { |
103 if (extension.uri == RtpExtension::kAudioLevelUri) { | 100 if (extension.uri == RtpExtension::kAudioLevelUri) { |
104 channel_proxy_->SetReceiveAudioLevelIndicationStatus(true, extension.id); | 101 channel_proxy_->SetReceiveAudioLevelIndicationStatus(true, extension.id); |
105 } else if (extension.uri == RtpExtension::kTransportSequenceNumberUri) { | 102 } else if (extension.uri == RtpExtension::kTransportSequenceNumberUri) { |
106 channel_proxy_->EnableReceiveTransportSequenceNumber(extension.id); | 103 channel_proxy_->EnableReceiveTransportSequenceNumber(extension.id); |
107 } else { | 104 } else { |
108 RTC_NOTREACHED() << "Unsupported RTP extension."; | 105 RTC_NOTREACHED() << "Unsupported RTP extension."; |
109 } | 106 } |
110 } | 107 } |
(...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
331 int AudioReceiveStream::SetVoiceEnginePlayout(bool playout) { | 328 int AudioReceiveStream::SetVoiceEnginePlayout(bool playout) { |
332 ScopedVoEInterface<VoEBase> base(voice_engine()); | 329 ScopedVoEInterface<VoEBase> base(voice_engine()); |
333 if (playout) { | 330 if (playout) { |
334 return base->StartPlayout(config_.voe_channel_id); | 331 return base->StartPlayout(config_.voe_channel_id); |
335 } else { | 332 } else { |
336 return base->StopPlayout(config_.voe_channel_id); | 333 return base->StopPlayout(config_.voe_channel_id); |
337 } | 334 } |
338 } | 335 } |
339 } // namespace internal | 336 } // namespace internal |
340 } // namespace webrtc | 337 } // namespace webrtc |
OLD | NEW |