Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(253)

Side by Side Diff: webrtc/modules/congestion_controller/congestion_controller.cc

Issue 2381833003: Change TWCC send interval to reduce overhead on low BW situations. (Closed)
Patch Set: fix unit-test build Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
162 observer_(observer), 162 observer_(observer),
163 packet_router_(new PacketRouter()), 163 packet_router_(new PacketRouter()),
164 pacer_(new PacedSender(clock_, packet_router_.get())), 164 pacer_(new PacedSender(clock_, packet_router_.get())),
165 remote_bitrate_estimator_( 165 remote_bitrate_estimator_(
166 new WrappingBitrateEstimator(remote_bitrate_observer, clock_)), 166 new WrappingBitrateEstimator(remote_bitrate_observer, clock_)),
167 bitrate_controller_( 167 bitrate_controller_(
168 BitrateController::CreateBitrateController(clock_, event_log)), 168 BitrateController::CreateBitrateController(clock_, event_log)),
169 probe_controller_(new ProbeController(pacer_.get(), clock_)), 169 probe_controller_(new ProbeController(pacer_.get(), clock_)),
170 retransmission_rate_limiter_( 170 retransmission_rate_limiter_(
171 new RateLimiter(clock, kRetransmitWindowSizeMs)), 171 new RateLimiter(clock, kRetransmitWindowSizeMs)),
172 remote_estimator_proxy_(clock_, packet_router_.get()), 172 remote_estimator_proxy_(clock_,
173 packet_router_.get(),
174 bitrate_controller_.get()),
173 transport_feedback_adapter_(clock_, bitrate_controller_.get()), 175 transport_feedback_adapter_(clock_, bitrate_controller_.get()),
174 min_bitrate_bps_(RemoteBitrateEstimator::kDefaultMinBitrateBps), 176 min_bitrate_bps_(RemoteBitrateEstimator::kDefaultMinBitrateBps),
175 max_bitrate_bps_(0), 177 max_bitrate_bps_(0),
176 last_reported_bitrate_bps_(0), 178 last_reported_bitrate_bps_(0),
177 last_reported_fraction_loss_(0), 179 last_reported_fraction_loss_(0),
178 last_reported_rtt_(0), 180 last_reported_rtt_(0),
179 network_state_(kNetworkUp) { 181 network_state_(kNetworkUp) {
180 Init(); 182 Init();
181 } 183 }
182 184
(...skipping 10 matching lines...) Expand all
193 pacer_(std::move(pacer)), 195 pacer_(std::move(pacer)),
194 remote_bitrate_estimator_( 196 remote_bitrate_estimator_(
195 new WrappingBitrateEstimator(remote_bitrate_observer, clock_)), 197 new WrappingBitrateEstimator(remote_bitrate_observer, clock_)),
196 // Constructed last as this object calls the provided callback on 198 // Constructed last as this object calls the provided callback on
197 // construction. 199 // construction.
198 bitrate_controller_( 200 bitrate_controller_(
199 BitrateController::CreateBitrateController(clock_, event_log)), 201 BitrateController::CreateBitrateController(clock_, event_log)),
200 probe_controller_(new ProbeController(pacer_.get(), clock_)), 202 probe_controller_(new ProbeController(pacer_.get(), clock_)),
201 retransmission_rate_limiter_( 203 retransmission_rate_limiter_(
202 new RateLimiter(clock, kRetransmitWindowSizeMs)), 204 new RateLimiter(clock, kRetransmitWindowSizeMs)),
203 remote_estimator_proxy_(clock_, packet_router_.get()), 205 remote_estimator_proxy_(clock_,
206 packet_router_.get(),
207 bitrate_controller_.get()),
204 transport_feedback_adapter_(clock_, bitrate_controller_.get()), 208 transport_feedback_adapter_(clock_, bitrate_controller_.get()),
205 min_bitrate_bps_(RemoteBitrateEstimator::kDefaultMinBitrateBps), 209 min_bitrate_bps_(RemoteBitrateEstimator::kDefaultMinBitrateBps),
206 max_bitrate_bps_(0), 210 max_bitrate_bps_(0),
207 last_reported_bitrate_bps_(0), 211 last_reported_bitrate_bps_(0),
208 last_reported_fraction_loss_(0), 212 last_reported_fraction_loss_(0),
209 last_reported_rtt_(0), 213 last_reported_rtt_(0),
210 network_state_(kNetworkUp) { 214 network_state_(kNetworkUp) {
211 Init(); 215 Init();
212 } 216 }
213 217
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
372 bool CongestionController::IsSendQueueFull() const { 376 bool CongestionController::IsSendQueueFull() const {
373 return pacer_->ExpectedQueueTimeMs() > PacedSender::kMaxQueueLengthMs; 377 return pacer_->ExpectedQueueTimeMs() > PacedSender::kMaxQueueLengthMs;
374 } 378 }
375 379
376 bool CongestionController::IsNetworkDown() const { 380 bool CongestionController::IsNetworkDown() const {
377 rtc::CritScope cs(&critsect_); 381 rtc::CritScope cs(&critsect_);
378 return network_state_ == kNetworkDown; 382 return network_state_ == kNetworkDown;
379 } 383 }
380 384
381 } // namespace webrtc 385 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698