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

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

Issue 1947873002: Reland of Remove SendPacer from ViEEncoder (patchset #13 id:240001 of https://codereview.we… (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Fixed CongestionController backwards compatibility Created 4 years, 7 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 | « webrtc/modules/pacing/bitrate_prober.h ('k') | webrtc/modules/pacing/mock/mock_paced_sender.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/modules/pacing/bitrate_prober.cc
diff --git a/webrtc/modules/pacing/bitrate_prober.cc b/webrtc/modules/pacing/bitrate_prober.cc
index fbd9b8174193aa55b9e9d371bc87b476d196caf1..ca09ee26118c8952e22d3184cff79d5d2b9798fc 100644
--- a/webrtc/modules/pacing/bitrate_prober.cc
+++ b/webrtc/modules/pacing/bitrate_prober.cc
@@ -21,7 +21,7 @@
namespace webrtc {
namespace {
-int ComputeDeltaFromBitrate(size_t packet_size, int bitrate_bps) {
+int ComputeDeltaFromBitrate(size_t packet_size, uint32_t bitrate_bps) {
assert(bitrate_bps > 0);
// Compute the time delta needed to send packet_size bytes at bitrate_bps
// bps. Result is in milliseconds.
@@ -52,7 +52,7 @@ bool BitrateProber::IsProbing() const {
return probing_state_ == kProbing;
}
-void BitrateProber::OnIncomingPacket(int bitrate_bps,
+void BitrateProber::OnIncomingPacket(uint32_t bitrate_bps,
size_t packet_size,
int64_t now_ms) {
// Don't initialize probing unless we have something large enough to start
@@ -66,7 +66,7 @@ void BitrateProber::OnIncomingPacket(int bitrate_bps,
const int kMaxNumProbes = 2;
const int kPacketsPerProbe = 5;
const float kProbeBitrateMultipliers[kMaxNumProbes] = {3, 6};
- int bitrates_bps[kMaxNumProbes];
+ uint32_t bitrates_bps[kMaxNumProbes];
std::stringstream bitrate_log;
bitrate_log << "Start probing for bandwidth, bitrates:";
for (int i = 0; i < kMaxNumProbes; ++i) {
« no previous file with comments | « webrtc/modules/pacing/bitrate_prober.h ('k') | webrtc/modules/pacing/mock/mock_paced_sender.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698