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

Unified Diff: media/cast/net/cast_transport_sender.h

Issue 765643006: Cast: Make receiver use cast_transport (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix end2end test Created 6 years 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: media/cast/net/cast_transport_sender.h
diff --git a/media/cast/net/cast_transport_sender.h b/media/cast/net/cast_transport_sender.h
index 46031a886e9938ba579c090dc0ce7a637ba4daf9..fc88a5c350b43242040c920388c5b16ebe986790 100644
--- a/media/cast/net/cast_transport_sender.h
+++ b/media/cast/net/cast_transport_sender.h
@@ -40,6 +40,8 @@ class NetLog;
namespace media {
namespace cast {
+struct RtpReceiverStatistics;
+struct RtcpTimeData;
// Following the initialization of either audio or video an initialization
// status will be sent via this callback.
@@ -56,11 +58,13 @@ class CastTransportSender : public base::NonThreadSafe {
static scoped_ptr<CastTransportSender> Create(
net::NetLog* net_log,
base::TickClock* clock,
+ const net::IPEndPoint& local_end_point,
const net::IPEndPoint& remote_end_point,
scoped_ptr<base::DictionaryValue> options,
const CastTransportStatusCallback& status_callback,
const BulkRawEventsCallback& raw_events_callback,
base::TimeDelta raw_events_callback_interval,
+ const PacketReceiverCallback& packet_callback,
const scoped_refptr<base::SingleThreadTaskRunner>& transport_task_runner);
virtual ~CastTransportSender() {}
@@ -100,6 +104,23 @@ class CastTransportSender : public base::NonThreadSafe {
// Returns a callback for receiving packets for testing purposes.
virtual PacketReceiverCallback PacketReceiverForTesting();
+
+ // The following functions are needed for receving.
+
+ // Add a valid SSRC. This is used to verify that incoming packets
+ // come from the right sender. Without valid SSRCs, the return address cannot
+ // be automatically established.
+ virtual void AddValidSsrc(uint32 ssrc) = 0;
+
+ // Send an RTCP message from receiver to sender.
+ virtual void SendRtcpFromRtpReceiver(
+ uint32 ssrc,
+ uint32 sender_ssrc,
+ const RtcpTimeData& time_data,
+ const RtcpCastMessage* cast_message,
+ base::TimeDelta target_delay,
+ const ReceiverRtcpEventSubscriber::RtcpEvents* rtcp_events,
+ const RtpReceiverStatistics* rtp_receiver_statistics) = 0;
};
} // namespace cast

Powered by Google App Engine
This is Rietveld 408576698