Chromium Code Reviews| Index: webrtc/modules/pacing/alr_detector.h |
| diff --git a/webrtc/modules/pacing/alr_detector.h b/webrtc/modules/pacing/alr_detector.h |
| index 11eeceaa988a65bdff24308e294902f1eaa23567..0a58c7fbad76f20aee1550b35c0322fbc707142a 100644 |
| --- a/webrtc/modules/pacing/alr_detector.h |
| +++ b/webrtc/modules/pacing/alr_detector.h |
| @@ -27,7 +27,6 @@ namespace webrtc { |
| // AlrDetector provides a signal that can be utilized to adjust |
| // estimate bandwidth. |
| // Note: This class is not thread-safe. |
| - |
| class AlrDetector { |
| public: |
| AlrDetector(); |
| @@ -57,8 +56,8 @@ class AlrDetector { |
| // kAlrEndUsagePercent. NOTE: This is intentionally conservative at the moment |
| // until BW adjustments of application limited region is fine tuned. |
| static constexpr int kDefaultAlrBandwidthUsagePercent = 65; |
| - static constexpr int kDefaultAlrStartBudgetLevelPercent = 20; |
| - static constexpr int kDefaultAlrStopBudgetLevelPercent = -20; |
| + static constexpr int kDefaultAlrStartBudgetLevelPercent = 80; |
|
terelius
2017/07/13 10:46:01
These numbers have changed a lot. How certain are
tschumi
2017/07/13 11:54:35
The detector was to slow in reporting the leafing
|
| + static constexpr int kDefaultAlrStopBudgetLevelPercent = 50; |
| static const char* kScreenshareProbingBweExperimentName; |
| void UpdateBudgetWithElapsedTime(int64_t delta_time_ms); |
| @@ -70,9 +69,24 @@ class AlrDetector { |
| int alr_stop_budget_level_percent_; |
| IntervalBudget alr_budget_; |
| + int estimated_bitrate_bps_; |
| rtc::Optional<int64_t> alr_started_time_ms_; |
| }; |
| +class AlrState { |
| + public: |
| + enum class Change { |
| + kEnded, |
| + kStarted, |
| + kNoChange, |
| + }; |
| + |
| + Change ChangeWhenAlrStartTimeIs(rtc::Optional<int64_t> alr_start_time_ms); |
| + |
| + private: |
| + bool was_in_alr_; |
| +}; |
| + |
| } // namespace webrtc |
| #endif // WEBRTC_MODULES_PACING_ALR_DETECTOR_H_ |