OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2015 The WebRTC project authors. All Rights Reserved. | 2 * Copyright 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 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
90 return; | 90 return; |
91 } | 91 } |
92 if (channel_) { | 92 if (channel_) { |
93 // Allow that SetOutputVolume fail. This is the normal case when the | 93 // Allow that SetOutputVolume fail. This is the normal case when the |
94 // underlying media channel has already been deleted. | 94 // underlying media channel has already been deleted. |
95 channel_->SetOutputVolume(ssrc_, 0); | 95 channel_->SetOutputVolume(ssrc_, 0); |
96 } | 96 } |
97 stopped_ = true; | 97 stopped_ = true; |
98 } | 98 } |
99 | 99 |
100 std::vector<RtpSource> AudioRtpReceiver::GetSources() const { | |
101 return channel_->GetSources(ssrc_); | |
102 } | |
103 | |
104 void AudioRtpReceiver::Reconfigure() { | 100 void AudioRtpReceiver::Reconfigure() { |
105 RTC_DCHECK(!stopped_); | 101 RTC_DCHECK(!stopped_); |
106 if (!channel_) { | 102 if (!channel_) { |
107 LOG(LS_ERROR) << "AudioRtpReceiver::Reconfigure: No audio channel exists."; | 103 LOG(LS_ERROR) << "AudioRtpReceiver::Reconfigure: No audio channel exists."; |
108 return; | 104 return; |
109 } | 105 } |
110 if (!channel_->SetOutputVolume(ssrc_, | 106 if (!channel_->SetOutputVolume(ssrc_, |
111 track_->enabled() ? cached_volume_ : 0)) { | 107 track_->enabled() ? cached_volume_ : 0)) { |
112 RTC_NOTREACHED(); | 108 RTC_NOTREACHED(); |
113 } | 109 } |
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
233 } | 229 } |
234 | 230 |
235 void VideoRtpReceiver::OnFirstPacketReceived(cricket::BaseChannel* channel) { | 231 void VideoRtpReceiver::OnFirstPacketReceived(cricket::BaseChannel* channel) { |
236 if (observer_) { | 232 if (observer_) { |
237 observer_->OnFirstPacketReceived(media_type()); | 233 observer_->OnFirstPacketReceived(media_type()); |
238 } | 234 } |
239 received_first_packet_ = true; | 235 received_first_packet_ = true; |
240 } | 236 } |
241 | 237 |
242 } // namespace webrtc | 238 } // namespace webrtc |
OLD | NEW |