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

Unified Diff: webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_abs_send_time.cc

Issue 1481003002: Revert of Make overuse estimator one dimensional. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 5 years, 1 month 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
Index: webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_abs_send_time.cc
diff --git a/webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_abs_send_time.cc b/webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_abs_send_time.cc
index cd919124fb3e424f1f0b2eb650ff8fde5515f602..51f7d4320a645be07aae0156ce956d64e6b3712e 100644
--- a/webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_abs_send_time.cc
+++ b/webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_abs_send_time.cc
@@ -102,6 +102,10 @@
: crit_sect_(CriticalSectionWrapper::CreateCriticalSection()),
observer_(observer),
clock_(clock),
+ ssrcs_(),
+ inter_arrival_(),
+ estimator_(OverUseDetectorOptions()),
+ detector_(OverUseDetectorOptions()),
incoming_bitrate_(kBitrateWindowMs, 8000),
last_process_time_(-1),
process_interval_ms_(kProcessIntervalMs),
@@ -267,6 +271,7 @@
uint32_t ts_delta = 0;
int64_t t_delta = 0;
+ int size_delta = 0;
// For now only try to detect probes while we don't have a valid estimate, and
// make sure the packet was paced. We currently assume that only packets
// larger than 200 bytes are paced by the sender.
@@ -296,10 +301,10 @@
new InterArrival((kTimestampGroupLengthMs << kInterArrivalShift) / 1000,
kTimestampToMs, true));
}
- if (inter_arrival_->ComputeDeltas(timestamp, arrival_time_ms, &ts_delta,
- &t_delta)) {
+ if (inter_arrival_->ComputeDeltas(timestamp, arrival_time_ms, payload_size,
+ &ts_delta, &t_delta, &size_delta)) {
double ts_delta_ms = (1000.0 * ts_delta) / (1 << kInterArrivalShift);
- estimator_.Update(t_delta, ts_delta_ms, detector_.State());
+ estimator_.Update(t_delta, ts_delta_ms, size_delta, detector_.State());
detector_.Detect(estimator_.offset(), ts_delta_ms,
estimator_.num_of_deltas(), arrival_time_ms);
UpdateStats(static_cast<int>(t_delta - ts_delta_ms), now_ms);

Powered by Google App Engine
This is Rietveld 408576698