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

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

Issue 1993113003: Refactor how padding is calculated. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Addressed review comments. Created 4 years, 6 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/paced_sender.h
diff --git a/webrtc/modules/pacing/paced_sender.h b/webrtc/modules/pacing/paced_sender.h
index 8879f12d0381abb7c9e6626dd897fb7eba03c9d2..1d9f2de2614d14567ca1b15d2d8e17e9770d007b 100644
--- a/webrtc/modules/pacing/paced_sender.h
+++ b/webrtc/modules/pacing/paced_sender.h
@@ -89,13 +89,15 @@ class PacedSender : public Module, public RtpPacketSender {
// |bitrate_bps| * kDefaultPaceMultiplier.
virtual void SetEstimatedBitrate(uint32_t bitrate_bps);
- // Sets the bitrate that has been allocated for encoders.
- // |allocated_bitrate| might be higher that the estimated available network
- // bitrate and if so, the pacer will send with |allocated_bitrate|.
- // Padding packets will be utilized to reach |padding_bitrate| unless enough
- // media packets are available.
- void SetAllocatedSendBitrate(int allocated_bitrate_bps,
- int padding_bitrate_bps);
+ // Sets the minimum send bitrate and maximum padding bitrate requested by send
+ // streams.
+ // |min_send_bitrate_bps| might be higher that the estimated available network
+ // bitrate and if so, the pacer will send with |min_send_bitrate_bps|.
+ // |max_padding_bitrate_bps| might be higher than the estimate available
+ // network bitrate and if so, the pacer will send padding packets to reach
+ // the min of the estimated available bitrate and |max_padding_bitrate_bps|.
+ void SetSendBitrateLimits(int min_send_bitrate_bps,
+ int max_padding_bitrate_bps);
// Returns true if we send the packet now, else it will add the packet
// information to the queue and call TimeToSendPacket when it's time to send.
@@ -157,6 +159,7 @@ class PacedSender : public Module, public RtpPacketSender {
// order to meet pace time constraint).
uint32_t estimated_bitrate_bps_ GUARDED_BY(critsect_);
uint32_t min_send_bitrate_kbps_ GUARDED_BY(critsect_);
+ uint32_t max_padding_bitrate_kbps_ GUARDED_BY(critsect_);
uint32_t pacing_bitrate_kbps_ GUARDED_BY(critsect_);
int64_t time_last_update_us_ GUARDED_BY(critsect_);
« no previous file with comments | « webrtc/modules/congestion_controller/include/congestion_controller.h ('k') | webrtc/modules/pacing/paced_sender.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698