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

Unified Diff: webrtc/media/base/capturerenderadapter.h

Issue 1655793003: Make cricket::VideoCapturer implement VideoSourceInterface (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Addressed comments. Created 4 years, 10 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/media/base/capturerenderadapter.h
diff --git a/webrtc/media/base/capturerenderadapter.h b/webrtc/media/base/capturerenderadapter.h
index ea457688ef1ced118eed26f72674450f3d749f4f..cc28d5092a442d704ef9a2c6d009720176bf0709 100644
--- a/webrtc/media/base/capturerenderadapter.h
+++ b/webrtc/media/base/capturerenderadapter.h
@@ -29,7 +29,9 @@ namespace cricket {
class VideoCapturer;
class VideoProcessor;
-class CaptureRenderAdapter : public sigslot::has_slots<> {
+// TODO(perkj): Considering removing CaptureRenderAdapter and replace it by
+// directly using cricket::VideoCapturer::AddSink.
+class CaptureRenderAdapter : public rtc::VideoSinkInterface<VideoFrame> {
pthatcher1 2016/02/08 20:59:39 This seems exactly like the VideoBroadcaster. Can
perkj_webrtc 2016/02/09 13:23:57 I had planned to do that in a follow up. But sure-
public:
static CaptureRenderAdapter* Create(VideoCapturer* video_capturer);
~CaptureRenderAdapter();
@@ -38,13 +40,13 @@ class CaptureRenderAdapter : public sigslot::has_slots<> {
void RemoveSink(rtc::VideoSinkInterface<VideoFrame>* sink);
VideoCapturer* video_capturer() { return video_capturer_; }
- private:
+ private:
explicit CaptureRenderAdapter(VideoCapturer* video_capturer);
void Init();
// Callback for frames received from the capturer.
- void OnVideoFrame(VideoCapturer* capturer, const VideoFrame* video_frame);
+ void OnFrame(const VideoFrame& frame) override;
// Just pointers since ownership is not handed over to this class.
std::vector<rtc::VideoSinkInterface<VideoFrame>*> sinks_;

Powered by Google App Engine
This is Rietveld 408576698