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

Side by Side Diff: webrtc/call/bitrate_allocator.cc

Issue 2121273003: Add more logging about the bwe state and VideoSendStream state. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Fixes. Created 4 years, 5 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
« no previous file with comments | « no previous file | webrtc/modules/congestion_controller/congestion_controller.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 150 matching lines...) Expand 10 before | Expand all | Expand 10 after
161 { 161 {
162 rtc::CritScope lock(&crit_sect_); 162 rtc::CritScope lock(&crit_sect_);
163 for (const auto& config : bitrate_observer_configs_) { 163 for (const auto& config : bitrate_observer_configs_) {
164 if (config.enforce_min_bitrate) { 164 if (config.enforce_min_bitrate) {
165 total_requested_min_bitrate += config.min_bitrate_bps; 165 total_requested_min_bitrate += config.min_bitrate_bps;
166 } 166 }
167 total_requested_padding_bitrate += config.pad_up_bitrate_bps; 167 total_requested_padding_bitrate += config.pad_up_bitrate_bps;
168 } 168 }
169 } 169 }
170 170
171 LOG(LS_INFO) << "UpdateAllocationLimits : total_requested_min_bitrate: "
172 << total_requested_min_bitrate
173 << "bps, total_requested_padding_bitrate: "
174 << total_requested_padding_bitrate << "bps";
171 limit_observer_->OnAllocationLimitsChanged(total_requested_min_bitrate, 175 limit_observer_->OnAllocationLimitsChanged(total_requested_min_bitrate,
172 total_requested_padding_bitrate); 176 total_requested_padding_bitrate);
173 } 177 }
174 178
175 void BitrateAllocator::RemoveObserver(BitrateAllocatorObserver* observer) { 179 void BitrateAllocator::RemoveObserver(BitrateAllocatorObserver* observer) {
176 { 180 {
177 rtc::CritScope lock(&crit_sect_); 181 rtc::CritScope lock(&crit_sect_);
178 auto it = FindObserverConfig(observer); 182 auto it = FindObserverConfig(observer);
179 if (it != bitrate_observer_configs_.end()) { 183 if (it != bitrate_observer_configs_.end()) {
180 bitrate_observer_configs_.erase(it); 184 bitrate_observer_configs_.erase(it);
(...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after
400 uint32_t extra_bitrate_per_observer = (bitrate - sum_min_bitrates) / 404 uint32_t extra_bitrate_per_observer = (bitrate - sum_min_bitrates) /
401 static_cast<uint32_t>(bitrate_observer_configs_.size()); 405 static_cast<uint32_t>(bitrate_observer_configs_.size());
402 for (const auto& observer_config : bitrate_observer_configs_) { 406 for (const auto& observer_config : bitrate_observer_configs_) {
403 if (observer_config.min_bitrate_bps + extra_bitrate_per_observer < 407 if (observer_config.min_bitrate_bps + extra_bitrate_per_observer <
404 MinBitrateWithHysteresis(observer_config)) 408 MinBitrateWithHysteresis(observer_config))
405 return false; 409 return false;
406 } 410 }
407 return true; 411 return true;
408 } 412 }
409 } // namespace webrtc 413 } // namespace webrtc
OLDNEW
« no previous file with comments | « no previous file | webrtc/modules/congestion_controller/congestion_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698