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

Unified Diff: webrtc/modules/pacing/bitrate_prober.h

Issue 2613543003: Fix BitrateProber to match the requested bitrate more precisely (Closed)
Patch Set: Limit number of retries Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | webrtc/modules/pacing/bitrate_prober.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/modules/pacing/bitrate_prober.h
diff --git a/webrtc/modules/pacing/bitrate_prober.h b/webrtc/modules/pacing/bitrate_prober.h
index e1a0a84f10a48cc714669686e6343fe573ce2d6e..86379ea9be463bf79947ddba1cea94b8f497067e 100644
--- a/webrtc/modules/pacing/bitrate_prober.h
+++ b/webrtc/modules/pacing/bitrate_prober.h
@@ -72,29 +72,38 @@ class BitrateProber {
};
// A probe cluster consists of a set of probes. Each probe in turn can be
- // divided into a number of packets to accomodate the MTU on the network.
+ // divided into a number of packets to accommodate the MTU on the network.
struct ProbeCluster {
int min_probes = 0;
- int sent_probes = 0;
int min_bytes = 0;
- int sent_bytes = 0;
int bitrate_bps = 0;
int id = -1;
+
+ int sent_probes = 0;
+ int sent_bytes = 0;
+ int64_t time_started_ms = -1;
+
+ int retries = 0;
};
// Resets the state of the prober and clears any cluster/timing data tracked.
void ResetState();
+ int64_t GetNextProbeTime(const ProbeCluster& cluster);
+
ProbingState probing_state_;
+
// Probe bitrate per packet. These are used to compute the delta relative to
// the previous probe packet based on the size and time when that packet was
// sent.
std::queue<ProbeCluster> clusters_;
- // A probe can include one or more packets.
- size_t probe_size_last_sent_;
- // The last time a probe was sent.
- int64_t time_last_probe_sent_ms_;
+
+ // Time the next probe should be sent when in kActive state.
+ int64_t next_probe_time_ms_;
+
int next_cluster_id_;
};
+
} // namespace webrtc
+
#endif // WEBRTC_MODULES_PACING_BITRATE_PROBER_H_
« no previous file with comments | « no previous file | webrtc/modules/pacing/bitrate_prober.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698