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 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
58 | 58 |
59 TransportFeedbackAdapter::~TransportFeedbackAdapter() {} | 59 TransportFeedbackAdapter::~TransportFeedbackAdapter() {} |
60 | 60 |
61 void TransportFeedbackAdapter::InitBwe() { | 61 void TransportFeedbackAdapter::InitBwe() { |
62 rtc::CritScope cs(&bwe_lock_); | 62 rtc::CritScope cs(&bwe_lock_); |
63 delay_based_bwe_.reset(new DelayBasedBwe(event_log_, clock_)); | 63 delay_based_bwe_.reset(new DelayBasedBwe(event_log_, clock_)); |
64 } | 64 } |
65 | 65 |
66 void TransportFeedbackAdapter::AddPacket(uint16_t sequence_number, | 66 void TransportFeedbackAdapter::AddPacket(uint16_t sequence_number, |
67 size_t length, | 67 size_t length, |
68 int probe_cluster_id) { | 68 const PacedPacketInfo& pacing_info) { |
69 rtc::CritScope cs(&lock_); | 69 rtc::CritScope cs(&lock_); |
70 if (send_side_bwe_with_overhead_) { | 70 if (send_side_bwe_with_overhead_) { |
71 length += transport_overhead_bytes_per_packet_; | 71 length += transport_overhead_bytes_per_packet_; |
72 } | 72 } |
73 send_time_history_.AddAndRemoveOld(sequence_number, length, probe_cluster_id); | 73 send_time_history_.AddAndRemoveOld(sequence_number, length, pacing_info); |
74 } | 74 } |
75 | 75 |
76 void TransportFeedbackAdapter::OnSentPacket(uint16_t sequence_number, | 76 void TransportFeedbackAdapter::OnSentPacket(uint16_t sequence_number, |
77 int64_t send_time_ms) { | 77 int64_t send_time_ms) { |
78 rtc::CritScope cs(&lock_); | 78 rtc::CritScope cs(&lock_); |
79 send_time_history_.OnSentPacket(sequence_number, send_time_ms); | 79 send_time_history_.OnSentPacket(sequence_number, send_time_ms); |
80 } | 80 } |
81 | 81 |
82 void TransportFeedbackAdapter::SetStartBitrate(int start_bitrate_bps) { | 82 void TransportFeedbackAdapter::SetStartBitrate(int start_bitrate_bps) { |
83 rtc::CritScope cs(&bwe_lock_); | 83 rtc::CritScope cs(&bwe_lock_); |
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
171 return last_packet_feedback_vector_; | 171 return last_packet_feedback_vector_; |
172 } | 172 } |
173 | 173 |
174 void TransportFeedbackAdapter::OnRttUpdate(int64_t avg_rtt_ms, | 174 void TransportFeedbackAdapter::OnRttUpdate(int64_t avg_rtt_ms, |
175 int64_t max_rtt_ms) { | 175 int64_t max_rtt_ms) { |
176 rtc::CritScope cs(&bwe_lock_); | 176 rtc::CritScope cs(&bwe_lock_); |
177 delay_based_bwe_->OnRttUpdate(avg_rtt_ms, max_rtt_ms); | 177 delay_based_bwe_->OnRttUpdate(avg_rtt_ms, max_rtt_ms); |
178 } | 178 } |
179 | 179 |
180 } // namespace webrtc | 180 } // namespace webrtc |
OLD | NEW |