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

Side by Side Diff: content/browser/renderer_host/media/video_capture_host.h

Issue 9015021: Remove DeleteTask and convert remaining users. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix last Linux gotchas (upload attempt #2) Created 8 years, 11 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 // 4 //
5 // VideoCaptureHost serves video capture related messages from 5 // VideoCaptureHost serves video capture related messages from
6 // VideCaptureMessageFilter which lives inside the render process. 6 // VideCaptureMessageFilter which lives inside the render process.
7 // 7 //
8 // This class is owned by BrowserRenderProcessHost, and instantiated on UI 8 // This class is owned by BrowserRenderProcessHost, and instantiated on UI
9 // thread, but all other operations and method calls happen on IO thread. 9 // thread, but all other operations and method calls happen on IO thread.
10 // 10 //
(...skipping 21 matching lines...) Expand all
32 // | < VideoCaptureMsg_StateChanged | 32 // | < VideoCaptureMsg_StateChanged |
33 // | (kStopped) | 33 // | (kStopped) |
34 // v v 34 // v v
35 35
36 #ifndef CONTENT_BROWSER_RENDERER_HOST_MEDIA_VIDEO_CAPTURE_HOST_H_ 36 #ifndef CONTENT_BROWSER_RENDERER_HOST_MEDIA_VIDEO_CAPTURE_HOST_H_
37 #define CONTENT_BROWSER_RENDERER_HOST_MEDIA_VIDEO_CAPTURE_HOST_H_ 37 #define CONTENT_BROWSER_RENDERER_HOST_MEDIA_VIDEO_CAPTURE_HOST_H_
38 38
39 #include <map> 39 #include <map>
40 40
41 #include "base/memory/ref_counted.h" 41 #include "base/memory/ref_counted.h"
42 #include "base/message_loop_helpers.h"
42 #include "content/browser/renderer_host/media/video_capture_controller.h" 43 #include "content/browser/renderer_host/media/video_capture_controller.h"
43 #include "content/common/content_export.h" 44 #include "content/common/content_export.h"
44 #include "content/public/browser/browser_message_filter.h" 45 #include "content/public/browser/browser_message_filter.h"
45 #include "ipc/ipc_message.h" 46 #include "ipc/ipc_message.h"
46 47
47 namespace content { 48 namespace content {
48 class ResourceContext; 49 class ResourceContext;
49 } // namespace content 50 } // namespace content
50 51
51 class CONTENT_EXPORT VideoCaptureHost 52 class CONTENT_EXPORT VideoCaptureHost
(...skipping 17 matching lines...) Expand all
69 int buffer_id, 70 int buffer_id,
70 base::Time timestamp) OVERRIDE; 71 base::Time timestamp) OVERRIDE;
71 virtual void OnFrameInfo(const VideoCaptureControllerID& id, 72 virtual void OnFrameInfo(const VideoCaptureControllerID& id,
72 int width, 73 int width,
73 int height, 74 int height,
74 int frame_per_second) OVERRIDE; 75 int frame_per_second) OVERRIDE;
75 virtual void OnReadyToDelete(const VideoCaptureControllerID& id) OVERRIDE; 76 virtual void OnReadyToDelete(const VideoCaptureControllerID& id) OVERRIDE;
76 77
77 private: 78 private:
78 friend class content::BrowserThread; 79 friend class content::BrowserThread;
79 friend class DeleteTask<VideoCaptureHost>; 80 friend class base::DeleteHelper<VideoCaptureHost>;
80 friend class MockVideoCaptureHost; 81 friend class MockVideoCaptureHost;
81 friend class VideoCaptureHostTest; 82 friend class VideoCaptureHostTest;
82 83
83 virtual ~VideoCaptureHost(); 84 virtual ~VideoCaptureHost();
84 85
85 // IPC message: Start capture on the VideoCaptureDevice referenced by 86 // IPC message: Start capture on the VideoCaptureDevice referenced by
86 // VideoCaptureParams::session_id. |device_id| is an id created by 87 // VideoCaptureParams::session_id. |device_id| is an id created by
87 // VideCaptureMessageFilter to identify a session 88 // VideCaptureMessageFilter to identify a session
88 // between a VideCaptureMessageFilter and a VideoCaptureHost. 89 // between a VideCaptureMessageFilter and a VideoCaptureHost.
89 void OnStartCapture(int device_id, 90 void OnStartCapture(int device_id,
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
139 // A map of VideoCaptureControllerID to its state and VideoCaptureController. 140 // A map of VideoCaptureControllerID to its state and VideoCaptureController.
140 EntryMap entries_; 141 EntryMap entries_;
141 142
142 // Used to get a pointer to VideoCaptureManager to start/stop capture devices. 143 // Used to get a pointer to VideoCaptureManager to start/stop capture devices.
143 const content::ResourceContext* resource_context_; 144 const content::ResourceContext* resource_context_;
144 145
145 DISALLOW_COPY_AND_ASSIGN(VideoCaptureHost); 146 DISALLOW_COPY_AND_ASSIGN(VideoCaptureHost);
146 }; 147 };
147 148
148 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_VIDEO_CAPTURE_HOST_H_ 149 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_VIDEO_CAPTURE_HOST_H_
OLDNEW
« no previous file with comments | « content/browser/renderer_host/media/audio_renderer_host.h ('k') | content/browser/renderer_host/pepper_file_message_filter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698