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

Unified Diff: webrtc/modules/congestion_controller/probe_controller.cc

Issue 2269873002: Avoid cluster set up at max bitrate at start (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@cleanup
Patch Set: Fix nit Created 4 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | webrtc/modules/congestion_controller/probe_controller_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/modules/congestion_controller/probe_controller.cc
diff --git a/webrtc/modules/congestion_controller/probe_controller.cc b/webrtc/modules/congestion_controller/probe_controller.cc
index cf7f3e1b6157b28f4250e7451cc3cf630b04e09f..e91e06efd555c9f8a0e9e852ad4979ee9088e1cc 100644
--- a/webrtc/modules/congestion_controller/probe_controller.cc
+++ b/webrtc/modules/congestion_controller/probe_controller.cc
@@ -54,11 +54,13 @@ void ProbeController::SetBitrates(int min_bitrate_bps,
}
// Only do probing if:
- // - we are mid-call, which we consider to be if
- // |estimated_bitrate_bps_| != 0, and
- // - the current bitrate is lower than the new |max_bitrate_bps|, and
- // - we actually want to increase the |max_bitrate_bps_|.
- if (estimated_bitrate_bps_ != 0 && estimated_bitrate_bps_ < max_bitrate_bps &&
+ // we are mid-call, which we consider to be if
+ // exponential probing is not active and
+ // |estimated_bitrate_bps_| is valid (> 0) and
+ // the current bitrate is lower than the new |max_bitrate_bps|, and
+ // we actually want to increase the |max_bitrate_bps_|.
+ if (state_ != State::kWaitingForProbingResult &&
+ estimated_bitrate_bps_ != 0 && estimated_bitrate_bps_ < max_bitrate_bps &&
max_bitrate_bps > max_bitrate_bps_) {
InitiateProbing({max_bitrate_bps}, kExponentialProbingDisabled);
}
« no previous file with comments | « no previous file | webrtc/modules/congestion_controller/probe_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698