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 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
57 return ss.str(); | 57 return ss.str(); |
58 } | 58 } |
59 | 59 |
60 namespace internal { | 60 namespace internal { |
61 AudioSendStream::AudioSendStream( | 61 AudioSendStream::AudioSendStream( |
62 const webrtc::AudioSendStream::Config& config, | 62 const webrtc::AudioSendStream::Config& config, |
63 const rtc::scoped_refptr<webrtc::AudioState>& audio_state, | 63 const rtc::scoped_refptr<webrtc::AudioState>& audio_state, |
64 rtc::TaskQueue* worker_queue, | 64 rtc::TaskQueue* worker_queue, |
65 CongestionController* congestion_controller, | 65 CongestionController* congestion_controller, |
66 BitrateAllocator* bitrate_allocator, | 66 BitrateAllocator* bitrate_allocator, |
67 RtcEventLog* event_log) | 67 RtcEventLog* event_log, |
| 68 RtcpRttStats* rtcp_rtt_stats) |
68 : worker_queue_(worker_queue), | 69 : worker_queue_(worker_queue), |
69 config_(config), | 70 config_(config), |
70 audio_state_(audio_state), | 71 audio_state_(audio_state), |
71 bitrate_allocator_(bitrate_allocator) { | 72 bitrate_allocator_(bitrate_allocator) { |
72 LOG(LS_INFO) << "AudioSendStream: " << config_.ToString(); | 73 LOG(LS_INFO) << "AudioSendStream: " << config_.ToString(); |
73 RTC_DCHECK_NE(config_.voe_channel_id, -1); | 74 RTC_DCHECK_NE(config_.voe_channel_id, -1); |
74 RTC_DCHECK(audio_state_.get()); | 75 RTC_DCHECK(audio_state_.get()); |
75 RTC_DCHECK(congestion_controller); | 76 RTC_DCHECK(congestion_controller); |
76 | 77 |
77 VoiceEngineImpl* voe_impl = static_cast<VoiceEngineImpl*>(voice_engine()); | 78 VoiceEngineImpl* voe_impl = static_cast<VoiceEngineImpl*>(voice_engine()); |
78 channel_proxy_ = voe_impl->GetChannelProxy(config_.voe_channel_id); | 79 channel_proxy_ = voe_impl->GetChannelProxy(config_.voe_channel_id); |
79 channel_proxy_->SetRtcEventLog(event_log); | 80 channel_proxy_->SetRtcEventLog(event_log); |
| 81 channel_proxy_->SetRtcpRttStats(rtcp_rtt_stats); |
80 channel_proxy_->RegisterSenderCongestionControlObjects( | 82 channel_proxy_->RegisterSenderCongestionControlObjects( |
81 congestion_controller->pacer(), | 83 congestion_controller->pacer(), |
82 congestion_controller->GetTransportFeedbackObserver(), | 84 congestion_controller->GetTransportFeedbackObserver(), |
83 congestion_controller->packet_router()); | 85 congestion_controller->packet_router()); |
84 channel_proxy_->SetRTCPStatus(true); | 86 channel_proxy_->SetRTCPStatus(true); |
85 channel_proxy_->SetLocalSSRC(config.rtp.ssrc); | 87 channel_proxy_->SetLocalSSRC(config.rtp.ssrc); |
86 channel_proxy_->SetRTCP_CNAME(config.rtp.c_name); | 88 channel_proxy_->SetRTCP_CNAME(config.rtp.c_name); |
87 // TODO(solenberg): Config NACK history window (which is a packet count), | 89 // TODO(solenberg): Config NACK history window (which is a packet count), |
88 // using the actual packet size for the configured codec. | 90 // using the actual packet size for the configured codec. |
89 channel_proxy_->SetNACKStatus(config_.rtp.nack.rtp_history_ms != 0, | 91 channel_proxy_->SetNACKStatus(config_.rtp.nack.rtp_history_ms != 0, |
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
280 | 282 |
281 VoiceEngine* AudioSendStream::voice_engine() const { | 283 VoiceEngine* AudioSendStream::voice_engine() const { |
282 internal::AudioState* audio_state = | 284 internal::AudioState* audio_state = |
283 static_cast<internal::AudioState*>(audio_state_.get()); | 285 static_cast<internal::AudioState*>(audio_state_.get()); |
284 VoiceEngine* voice_engine = audio_state->voice_engine(); | 286 VoiceEngine* voice_engine = audio_state->voice_engine(); |
285 RTC_DCHECK(voice_engine); | 287 RTC_DCHECK(voice_engine); |
286 return voice_engine; | 288 return voice_engine; |
287 } | 289 } |
288 } // namespace internal | 290 } // namespace internal |
289 } // namespace webrtc | 291 } // namespace webrtc |
OLD | NEW |