| 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 275 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 286 int sample_rate_hz, | 286 int sample_rate_hz, |
| 287 AudioFrame* audio_frame) { | 287 AudioFrame* audio_frame) { |
| 288 return channel_proxy_->GetAudioFrameWithInfo(sample_rate_hz, audio_frame); | 288 return channel_proxy_->GetAudioFrameWithInfo(sample_rate_hz, audio_frame); |
| 289 } | 289 } |
| 290 | 290 |
| 291 int AudioReceiveStream::PreferredSampleRate() const { | 291 int AudioReceiveStream::PreferredSampleRate() const { |
| 292 return channel_proxy_->NeededFrequency(); | 292 return channel_proxy_->NeededFrequency(); |
| 293 } | 293 } |
| 294 | 294 |
| 295 int AudioReceiveStream::Ssrc() const { | 295 int AudioReceiveStream::Ssrc() const { |
| 296 return config_.rtp.local_ssrc; | 296 return config_.rtp.remote_ssrc; |
| 297 } | 297 } |
| 298 | 298 |
| 299 internal::AudioState* AudioReceiveStream::audio_state() const { | 299 internal::AudioState* AudioReceiveStream::audio_state() const { |
| 300 auto* audio_state = static_cast<internal::AudioState*>(audio_state_.get()); | 300 auto* audio_state = static_cast<internal::AudioState*>(audio_state_.get()); |
| 301 RTC_DCHECK(audio_state); | 301 RTC_DCHECK(audio_state); |
| 302 return audio_state; | 302 return audio_state; |
| 303 } | 303 } |
| 304 | 304 |
| 305 VoiceEngine* AudioReceiveStream::voice_engine() const { | 305 VoiceEngine* AudioReceiveStream::voice_engine() const { |
| 306 auto* voice_engine = audio_state()->voice_engine(); | 306 auto* voice_engine = audio_state()->voice_engine(); |
| 307 RTC_DCHECK(voice_engine); | 307 RTC_DCHECK(voice_engine); |
| 308 return voice_engine; | 308 return voice_engine; |
| 309 } | 309 } |
| 310 | 310 |
| 311 int AudioReceiveStream::SetVoiceEnginePlayout(bool playout) { | 311 int AudioReceiveStream::SetVoiceEnginePlayout(bool playout) { |
| 312 ScopedVoEInterface<VoEBase> base(voice_engine()); | 312 ScopedVoEInterface<VoEBase> base(voice_engine()); |
| 313 if (playout) { | 313 if (playout) { |
| 314 return base->StartPlayout(config_.voe_channel_id); | 314 return base->StartPlayout(config_.voe_channel_id); |
| 315 } else { | 315 } else { |
| 316 return base->StopPlayout(config_.voe_channel_id); | 316 return base->StopPlayout(config_.voe_channel_id); |
| 317 } | 317 } |
| 318 } | 318 } |
| 319 | 319 |
| 320 } // namespace internal | 320 } // namespace internal |
| 321 } // namespace webrtc | 321 } // namespace webrtc |
| OLD | NEW |