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 2896 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2907 bool Channel::GetCodecFECStatus() { | 2907 bool Channel::GetCodecFECStatus() { |
2908 return codec_manager_.GetStackParams()->use_codec_fec; | 2908 return codec_manager_.GetStackParams()->use_codec_fec; |
2909 } | 2909 } |
2910 | 2910 |
2911 void Channel::SetNACKStatus(bool enable, int maxNumberOfPackets) { | 2911 void Channel::SetNACKStatus(bool enable, int maxNumberOfPackets) { |
2912 // None of these functions can fail. | 2912 // None of these functions can fail. |
2913 // If pacing is enabled we always store packets. | 2913 // If pacing is enabled we always store packets. |
2914 if (!pacing_enabled_) | 2914 if (!pacing_enabled_) |
2915 _rtpRtcpModule->SetStorePacketsStatus(enable, maxNumberOfPackets); | 2915 _rtpRtcpModule->SetStorePacketsStatus(enable, maxNumberOfPackets); |
2916 rtp_receive_statistics_->SetMaxReorderingThreshold(maxNumberOfPackets); | 2916 rtp_receive_statistics_->SetMaxReorderingThreshold(maxNumberOfPackets); |
2917 rtp_receiver_->SetNACKStatus(enable ? kNackRtcp : kNackOff); | |
2918 if (enable) | 2917 if (enable) |
2919 audio_coding_->EnableNack(maxNumberOfPackets); | 2918 audio_coding_->EnableNack(maxNumberOfPackets); |
2920 else | 2919 else |
2921 audio_coding_->DisableNack(); | 2920 audio_coding_->DisableNack(); |
2922 } | 2921 } |
2923 | 2922 |
2924 // Called when we are missing one or more packets. | 2923 // Called when we are missing one or more packets. |
2925 int Channel::ResendPackets(const uint16_t* sequence_numbers, int length) { | 2924 int Channel::ResendPackets(const uint16_t* sequence_numbers, int length) { |
2926 return _rtpRtcpModule->SendNACK(sequence_numbers, length); | 2925 return _rtpRtcpModule->SendNACK(sequence_numbers, length); |
2927 } | 2926 } |
(...skipping 618 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3546 int64_t min_rtt = 0; | 3545 int64_t min_rtt = 0; |
3547 if (_rtpRtcpModule->RTT(remoteSSRC, &rtt, &avg_rtt, &min_rtt, &max_rtt) != | 3546 if (_rtpRtcpModule->RTT(remoteSSRC, &rtt, &avg_rtt, &min_rtt, &max_rtt) != |
3548 0) { | 3547 0) { |
3549 return 0; | 3548 return 0; |
3550 } | 3549 } |
3551 return rtt; | 3550 return rtt; |
3552 } | 3551 } |
3553 | 3552 |
3554 } // namespace voe | 3553 } // namespace voe |
3555 } // namespace webrtc | 3554 } // namespace webrtc |
OLD | NEW |