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

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

Issue 1350163005: Avoid circular dependency rtp_rtcp <-> paced_sender (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Rebase Created 5 years, 3 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.cc ('k') | webrtc/modules/pacing/include/packet_router.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/modules/pacing/include/paced_sender.h
diff --git a/webrtc/modules/pacing/include/paced_sender.h b/webrtc/modules/pacing/include/paced_sender.h
index 645999d50785bdd74614aa8413adb61570220e84..afb196fe4505539081c246167345455e6ebb39ee 100644
--- a/webrtc/modules/pacing/include/paced_sender.h
+++ b/webrtc/modules/pacing/include/paced_sender.h
@@ -17,6 +17,7 @@
#include "webrtc/base/scoped_ptr.h"
#include "webrtc/base/thread_annotations.h"
#include "webrtc/modules/interface/module.h"
+#include "webrtc/modules/rtp_rtcp/interface/rtp_rtcp_defines.h"
#include "webrtc/typedefs.h"
namespace webrtc {
@@ -30,16 +31,8 @@ struct Packet;
class PacketQueue;
} // namespace paced_sender
-class PacedSender : public Module {
+class PacedSender : public Module, public RtpPacketSender {
public:
- enum Priority {
- kHighPriority = 0, // Pass through; will be sent immediately.
- kNormalPriority = 2, // Put in back of the line.
- kLowPriority = 3, // Put in back of the low priority line.
- };
- // Low priority packets are mixed with the normal priority packets
- // while we are paused.
-
class Callback {
public:
// Note: packets sent as a result of a callback should not pass by this
@@ -68,6 +61,8 @@ class PacedSender : public Module {
// overshoots from the encoder.
static const float kDefaultPaceMultiplier;
+ static const size_t kMinProbePacketSize = 200;
+
PacedSender(Clock* clock,
Callback* callback,
int bitrate_kbps,
@@ -103,12 +98,12 @@ class PacedSender : public Module {
// 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.
- virtual bool SendPacket(Priority priority,
- uint32_t ssrc,
- uint16_t sequence_number,
- int64_t capture_time_ms,
- size_t bytes,
- bool retransmission);
+ bool SendPacket(RtpPacketSender::Priority priority,
+ uint32_t ssrc,
+ uint16_t sequence_number,
+ int64_t capture_time_ms,
+ size_t bytes,
+ bool retransmission) override;
// Returns the time since the oldest queued packet was enqueued.
virtual int64_t QueueInMs() const;
« no previous file with comments | « webrtc/modules/pacing/bitrate_prober.cc ('k') | webrtc/modules/pacing/include/packet_router.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698