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

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

Issue 1946173002: Bitrate prober now keep track of probing cluster id. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Removed commented code. Created 4 years, 8 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') | webrtc/modules/pacing/bitrate_prober.cc » ('J')
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 84fbc522fc9e3b2e4d87d19dc53741c82a549367..9b15760506230c8da648f9e17609520679468531 100644
--- a/webrtc/modules/pacing/bitrate_prober.h
+++ b/webrtc/modules/pacing/bitrate_prober.h
@@ -13,6 +13,7 @@
#include <cstddef>
#include <list>
+#include <queue>
#include "webrtc/typedefs.h"
@@ -40,6 +41,9 @@ class BitrateProber {
// get accurate probing.
int TimeUntilNextProbe(int64_t now_ms);
+ // Which cluster that is currently being used for probing.
+ int CurrentClusterId() const;
+
// Returns the number of bytes that the prober recommends for the next probe
// packet.
size_t RecommendedPacketSize() const;
@@ -51,13 +55,21 @@ class BitrateProber {
private:
enum ProbingState { kDisabled, kAllowedToProbe, kProbing, kWait };
+ struct ProbeCluster {
+ uint8_t max_probe_packets = 0;
+ uint8_t sent_probe_packets = 0;
stefan-webrtc 2016/05/04 09:42:35 int for these too?
philipel 2016/05/04 10:36:32 Done.
+ int probe_bitrate = 0;
stefan-webrtc 2016/05/04 09:42:35 probe_bitrate_bps
philipel 2016/05/04 10:36:32 Done.
+ int id = -1;
+ };
+
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::list<int> probe_bitrates_;
+ std::queue<ProbeCluster> clusters_;
size_t packet_size_last_send_;
int64_t time_last_send_ms_;
+ int 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') | webrtc/modules/pacing/bitrate_prober.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698