OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2016 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2016 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 |
11 #include "webrtc/modules/pacing/alr_detector.h" | 11 #include "webrtc/modules/pacing/alr_detector.h" |
12 | 12 |
13 #include <string> | 13 #include <string> |
14 | 14 |
15 #include "webrtc/rtc_base/checks.h" | 15 #include "webrtc/rtc_base/checks.h" |
16 #include "webrtc/rtc_base/format_macros.h" | 16 #include "webrtc/rtc_base/format_macros.h" |
17 #include "webrtc/rtc_base/logging.h" | 17 #include "webrtc/rtc_base/logging.h" |
18 #include "webrtc/rtc_base/timeutils.h" | 18 #include "webrtc/rtc_base/timeutils.h" |
19 #include "webrtc/system_wrappers/include/field_trial.h" | 19 #include "webrtc/system_wrappers/include/field_trial.h" |
20 | 20 |
21 namespace webrtc { | 21 namespace webrtc { |
22 | 22 |
23 const char* AlrDetector::kScreenshareProbingBweExperimentName = | 23 const char AlrDetector::kScreenshareProbingBweExperimentName[] = |
24 "WebRTC-ProbingScreenshareBwe"; | 24 "WebRTC-ProbingScreenshareBwe"; |
25 | 25 |
26 AlrDetector::AlrDetector() | 26 AlrDetector::AlrDetector() |
27 : bandwidth_usage_percent_(kDefaultAlrBandwidthUsagePercent), | 27 : bandwidth_usage_percent_(kDefaultAlrBandwidthUsagePercent), |
28 alr_start_budget_level_percent_(kDefaultAlrStartBudgetLevelPercent), | 28 alr_start_budget_level_percent_(kDefaultAlrStartBudgetLevelPercent), |
29 alr_stop_budget_level_percent_(kDefaultAlrStopBudgetLevelPercent), | 29 alr_stop_budget_level_percent_(kDefaultAlrStopBudgetLevelPercent), |
30 alr_budget_(0, true) { | 30 alr_budget_(0, true) { |
31 rtc::Optional<AlrExperimentSettings> experiment_settings = | 31 rtc::Optional<AlrExperimentSettings> experiment_settings = |
32 ParseAlrSettingsFromFieldTrial(); | 32 ParseAlrSettingsFromFieldTrial(); |
33 if (experiment_settings) { | 33 if (experiment_settings) { |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
97 << ", ALR end budget level percent: " | 97 << ", ALR end budget level percent: " |
98 << settings.alr_start_budget_level_percent | 98 << settings.alr_start_budget_level_percent |
99 << ", ALR end budget level percent: " | 99 << ", ALR end budget level percent: " |
100 << settings.alr_stop_budget_level_percent; | 100 << settings.alr_stop_budget_level_percent; |
101 } | 101 } |
102 | 102 |
103 return ret; | 103 return ret; |
104 } | 104 } |
105 | 105 |
106 } // namespace webrtc | 106 } // namespace webrtc |
OLD | NEW |