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

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

Issue 2243823002: Added ProbeBitrate(bitrate_bps, num_probes) to BitrateProber. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Clean up api Created 4 years, 4 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
Index: webrtc/modules/pacing/bitrate_prober.h
diff --git a/webrtc/modules/pacing/bitrate_prober.h b/webrtc/modules/pacing/bitrate_prober.h
index c2f9ad8c4713db52ea8d000b6ca1d554d31d5adf..7b39ff5e54b292c4b20185b0843d6ca722a36842 100644
--- a/webrtc/modules/pacing/bitrate_prober.h
+++ b/webrtc/modules/pacing/bitrate_prober.h
@@ -11,9 +11,7 @@
#ifndef WEBRTC_MODULES_PACING_BITRATE_PROBER_H_
#define WEBRTC_MODULES_PACING_BITRATE_PROBER_H_
-#include <cstddef>
-#include <list>
-#include <queue>
+#include <deque>
#include "webrtc/typedefs.h"
@@ -35,9 +33,11 @@ class BitrateProber {
// Initializes a new probing session if the prober is allowed to probe. Does
// not initialize the prober unless the packet size is large enough to probe
// with.
- void OnIncomingPacket(uint32_t bitrate_bps,
- size_t packet_size,
- int64_t now_ms);
+ void OnIncomingPacket(size_t packet_size);
+
+ // Create a cluster used to probe for |bitrate_bps| with |num_packets| number
+ // of packets.
+ void ProbeBitrate(uint32_t bitrate_bps, int num_packets);
stefan-webrtc 2016/08/12 13:19:59 ProbeAtBitrate or CreateProbeAtBitrate?
philipel 2016/08/12 14:08:07 Change to ProbeAtBitrate.
// Returns the number of milliseconds until the next packet should be sent to
// get accurate probing.
@@ -82,7 +82,7 @@ class BitrateProber {
// 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_;
+ std::deque<ProbeCluster> clusters_;
size_t packet_size_last_sent_;
// The last time a probe was sent.
int64_t time_last_probe_sent_ms_;

Powered by Google App Engine
This is Rietveld 408576698