OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 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 2909 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2920 void Channel::EnableSendTransportSequenceNumber(int id) { | 2920 void Channel::EnableSendTransportSequenceNumber(int id) { |
2921 int ret = | 2921 int ret = |
2922 SetSendRtpHeaderExtension(true, kRtpExtensionTransportSequenceNumber, id); | 2922 SetSendRtpHeaderExtension(true, kRtpExtensionTransportSequenceNumber, id); |
2923 RTC_DCHECK_EQ(0, ret); | 2923 RTC_DCHECK_EQ(0, ret); |
2924 } | 2924 } |
2925 | 2925 |
2926 void Channel::SetCongestionControlObjects( | 2926 void Channel::SetCongestionControlObjects( |
2927 RtpPacketSender* rtp_packet_sender, | 2927 RtpPacketSender* rtp_packet_sender, |
2928 TransportFeedbackObserver* transport_feedback_observer, | 2928 TransportFeedbackObserver* transport_feedback_observer, |
2929 PacketRouter* packet_router) { | 2929 PacketRouter* packet_router) { |
2930 RTC_DCHECK(feedback_observer_proxy_.get()); | |
2931 RTC_DCHECK(seq_num_allocator_proxy_.get()); | |
2932 RTC_DCHECK(rtp_packet_sender_proxy_.get()); | |
2933 RTC_DCHECK(packet_router != nullptr || packet_router_ != nullptr); | 2930 RTC_DCHECK(packet_router != nullptr || packet_router_ != nullptr); |
the sun
2015/12/22 00:14:14
Since we are relying on the channel only being use
stefan-webrtc
2016/01/07 13:43:41
I think it's non-trivial to test those without kno
| |
2934 feedback_observer_proxy_->SetTransportFeedbackObserver( | 2931 if (transport_feedback_observer) { |
2935 transport_feedback_observer); | 2932 RTC_DCHECK(feedback_observer_proxy_.get()); |
2936 seq_num_allocator_proxy_->SetSequenceNumberAllocator(packet_router); | 2933 feedback_observer_proxy_->SetTransportFeedbackObserver( |
2937 rtp_packet_sender_proxy_->SetPacketSender(rtp_packet_sender); | 2934 transport_feedback_observer); |
2935 } | |
2936 if (rtp_packet_sender) { | |
2937 RTC_DCHECK(rtp_packet_sender_proxy_.get()); | |
2938 rtp_packet_sender_proxy_->SetPacketSender(rtp_packet_sender); | |
2939 } | |
2940 if (seq_num_allocator_proxy_.get()) | |
2941 seq_num_allocator_proxy_->SetSequenceNumberAllocator(packet_router); | |
2938 _rtpRtcpModule->SetStorePacketsStatus(rtp_packet_sender != nullptr, 600); | 2942 _rtpRtcpModule->SetStorePacketsStatus(rtp_packet_sender != nullptr, 600); |
2939 if (packet_router != nullptr) { | 2943 if (packet_router != nullptr) { |
2940 packet_router->AddRtpModule(_rtpRtcpModule.get()); | 2944 packet_router->AddRtpModule(_rtpRtcpModule.get()); |
2941 } else { | 2945 } else { |
2942 packet_router_->RemoveRtpModule(_rtpRtcpModule.get()); | 2946 packet_router_->RemoveRtpModule(_rtpRtcpModule.get()); |
2943 } | 2947 } |
2944 packet_router_ = packet_router; | 2948 packet_router_ = packet_router; |
2945 } | 2949 } |
2946 | 2950 |
2947 void Channel::SetRTCPStatus(bool enable) { | 2951 void Channel::SetRTCPStatus(bool enable) { |
(...skipping 1155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
4103 int64_t min_rtt = 0; | 4107 int64_t min_rtt = 0; |
4104 if (_rtpRtcpModule->RTT(remoteSSRC, &rtt, &avg_rtt, &min_rtt, &max_rtt) | 4108 if (_rtpRtcpModule->RTT(remoteSSRC, &rtt, &avg_rtt, &min_rtt, &max_rtt) |
4105 != 0) { | 4109 != 0) { |
4106 return 0; | 4110 return 0; |
4107 } | 4111 } |
4108 return rtt; | 4112 return rtt; |
4109 } | 4113 } |
4110 | 4114 |
4111 } // namespace voe | 4115 } // namespace voe |
4112 } // namespace webrtc | 4116 } // namespace webrtc |
OLD | NEW |