Propagating total_bitrate_bps from BitrateAllocator to ProbeController, part 3.
Trigger on total bitrate change. Bug: webrtc:8955 Change-Id: I2373a1b7f139c7ea748a9641593e714d6895c8f6 Reviewed-on: https://webrtc-review.googlesource.com/59323 Reviewed-by: Stefan Holmer <stefan@webrtc.org> Reviewed-by: Sebastian Jansson <srte@webrtc.org> Commit-Queue: Philip Eliasson <philipel@webrtc.org> Cr-Commit-Position: refs/heads/master@{#22323}
This commit is contained in:
@ -125,6 +125,19 @@ void ProbeController::SetBitrates(int64_t min_bitrate_bps,
|
||||
}
|
||||
}
|
||||
|
||||
void ProbeController::OnMaxTotalAllocatedBitrate(
|
||||
int64_t max_total_allocated_bitrate) {
|
||||
rtc::CritScope cs(&critsect_);
|
||||
// TODO(philipel): Should |max_total_allocated_bitrate| be used as a limit for
|
||||
// ALR probing?
|
||||
if (estimated_bitrate_bps_ != 0 &&
|
||||
estimated_bitrate_bps_ < max_bitrate_bps_ &&
|
||||
estimated_bitrate_bps_ < max_total_allocated_bitrate) {
|
||||
InitiateProbing(clock_->TimeInMilliseconds(), {max_total_allocated_bitrate},
|
||||
false);
|
||||
}
|
||||
}
|
||||
|
||||
void ProbeController::OnNetworkStateChanged(NetworkState network_state) {
|
||||
rtc::CritScope cs(&critsect_);
|
||||
network_state_ = network_state;
|
||||
|
||||
Reference in New Issue
Block a user