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

Unified Diff: media/video/capture/video_capture.h

Issue 8037055: Add OnRemoved() in VideoCapture::EventHandler API (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: change needed for unit test Created 9 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 | « content/renderer/media/video_capture_module_impl.cc ('k') | media/video/capture/video_capture_proxy.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/video/capture/video_capture.h
===================================================================
--- media/video/capture/video_capture.h (revision 102835)
+++ media/video/capture/video_capture.h (working copy)
@@ -66,6 +66,10 @@
// Notify client that video capture has hit some error |error_code|.
virtual void OnError(VideoCapture* capture, int error_code) = 0;
+ // Notify client that the client has been removed and no more calls will be
+ // received.
+ virtual void OnRemoved(VideoCapture* capture) = 0;
+
// Notify client that a buffer is available.
virtual void OnBufferReady(VideoCapture* capture,
scoped_refptr<VideoFrameBuffer> buffer) = 0;
@@ -93,10 +97,12 @@
// Request video capture to start capturing with |capability|.
// Also register |handler| with video capture for event handling.
+ // |handler| must remain valid until it has received |OnRemoved()|.
virtual void StartCapture(EventHandler* handler,
const VideoCaptureCapability& capability) = 0;
// Request video capture to stop capturing for client |handler|.
+ // |handler| must remain valid until it has received |OnRemoved()|.
virtual void StopCapture(EventHandler* handler) = 0;
// Feed buffer to video capture when done with it.
« no previous file with comments | « content/renderer/media/video_capture_module_impl.cc ('k') | media/video/capture/video_capture_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698