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

Unified Diff: webrtc/api/rtpreceiverinterface.h

Issue 1999853002: Forward the SignalFirstPacketReceived to RtpReceiver. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Make the destructor of RtpReceiverObserverInterface virtual. 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
Index: webrtc/api/rtpreceiverinterface.h
diff --git a/webrtc/api/rtpreceiverinterface.h b/webrtc/api/rtpreceiverinterface.h
index ef4f0e113f36d297725e49ce17dcf530c0cdd3b3..710067e9b177c3b1cf3a320e455ef677a593745a 100644
--- a/webrtc/api/rtpreceiverinterface.h
+++ b/webrtc/api/rtpreceiverinterface.h
@@ -20,9 +20,18 @@
#include "webrtc/api/proxy.h"
#include "webrtc/base/refcount.h"
#include "webrtc/base/scoped_ref_ptr.h"
+#include "webrtc/pc/mediasession.h"
namespace webrtc {
+class RtpReceiverObserverInterface : public rtc::RefCountInterface {
pthatcher2 2016/05/20 20:23:14 Why does it need to be refcounted?
+ public:
+ virtual void onFirstPacketReceived(cricket::MediaType media_type) = 0;
pthatcher2 2016/05/20 20:23:14 OnFirstPacketReceived
+
+ protected:
+ virtual ~RtpReceiverObserverInterface() {}
+};
+
class RtpReceiverInterface : public rtc::RefCountInterface {
public:
virtual rtc::scoped_refptr<MediaStreamTrackInterface> track() const = 0;
@@ -39,6 +48,9 @@ class RtpReceiverInterface : public rtc::RefCountInterface {
virtual RtpParameters GetParameters() const = 0;
virtual bool SetParameters(const RtpParameters& parameters) = 0;
+ virtual void RegisterRtpReceiverObserver(
+ RtpReceiverObserverInterface* observer) = 0;
+
protected:
virtual ~RtpReceiverInterface() {}
};
@@ -50,6 +62,7 @@ PROXY_CONSTMETHOD0(std::string, id)
PROXY_METHOD0(void, Stop)
PROXY_CONSTMETHOD0(RtpParameters, GetParameters);
PROXY_METHOD1(bool, SetParameters, const RtpParameters&)
+PROXY_METHOD1(void, RegisterRtpReceiverObserver, RtpReceiverObserverInterface*);
END_SIGNALING_PROXY()
} // namespace webrtc

Powered by Google App Engine
This is Rietveld 408576698