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

Unified Diff: webrtc/api/rtpsenderinterface.h

Issue 1827023002: Get VideoCapturer stats via VideoTrackSourceInterface in StatsCollector, (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Move StatsReport logic to VideoRtpSender. Created 4 years, 9 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/rtpsenderinterface.h
diff --git a/webrtc/api/rtpsenderinterface.h b/webrtc/api/rtpsenderinterface.h
index 776d01ace6b4457a960dbcf1795d70e8de11c805..09de1d1637502bb54c65b232d794bf27335dc9c4 100644
--- a/webrtc/api/rtpsenderinterface.h
+++ b/webrtc/api/rtpsenderinterface.h
@@ -19,6 +19,7 @@
#include "webrtc/api/mediastreaminterface.h"
#include "webrtc/api/proxy.h"
#include "webrtc/api/rtpparameters.h"
+#include "webrtc/api/statstypes.h"
#include "webrtc/base/refcount.h"
#include "webrtc/base/scoped_ref_ptr.h"
#include "webrtc/pc/mediasession.h"
@@ -55,6 +56,10 @@ class RtpSenderInterface : public rtc::RefCountInterface {
virtual RtpParameters GetParameters() const = 0;
virtual bool SetParameters(const RtpParameters& parameters) = 0;
+ // Returns a scoped_refptr(nullptr) if there are no stats.
perkj_webrtc 2016/03/29 11:03:39 ? StatsReport::Id is a scoped_refptr?
nisse-webrtc 2016/03/29 11:37:31 Yes, defined in statstypes.h as typedef rtc::sc
+ virtual StatsReport::Id stats_id() = 0;
+ virtual void ReportStats(StatsReport* report) = 0;
perkj_webrtc 2016/03/29 11:03:39 Prefer GetStats anyway (saw your comments) since i
nisse-webrtc 2016/03/29 11:37:31 Most other GetStats methods either take an observe
tommi 2016/03/30 11:46:45 Is this method's implementation expected to block
nisse-webrtc 2016/03/30 12:09:31 It shouldn't block. If the RtpSender is connected
+
protected:
virtual ~RtpSenderInterface() {}
};
@@ -72,6 +77,8 @@ PROXY_CONSTMETHOD0(std::string, stream_id)
PROXY_METHOD0(void, Stop)
PROXY_CONSTMETHOD0(RtpParameters, GetParameters);
PROXY_METHOD1(bool, SetParameters, const RtpParameters&)
+PROXY_METHOD0(StatsReport::Id, stats_id)
+PROXY_METHOD1(void, ReportStats, StatsReport*)
tommi 2016/03/30 11:46:45 as is, all proxy methods involve a synchronous thr
END_PROXY()
} // namespace webrtc

Powered by Google App Engine
This is Rietveld 408576698