| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // VideoCaptureController is the glue between VideoCaptureHost, | 5 // VideoCaptureController is the glue between VideoCaptureHost, |
| 6 // VideoCaptureManager and VideoCaptureDevice. | 6 // VideoCaptureManager and VideoCaptureDevice. |
| 7 // It provides functions for VideoCaptureHost to start a VideoCaptureDevice and | 7 // It provides functions for VideoCaptureHost to start a VideoCaptureDevice and |
| 8 // is responsible for keeping track of shared DIBs and filling them with I420 | 8 // is responsible for keeping track of shared DIBs and filling them with I420 |
| 9 // video frames for IPC communication between VideoCaptureHost and | 9 // video frames for IPC communication between VideoCaptureHost and |
| 10 // VideoCaptureMessageFilter. | 10 // VideoCaptureMessageFilter. |
| (...skipping 15 matching lines...) Expand all Loading... |
| 26 #include "content/browser/renderer_host/media/video_capture_controller_event_han
dler.h" | 26 #include "content/browser/renderer_host/media/video_capture_controller_event_han
dler.h" |
| 27 #include "content/common/media/video_capture.h" | 27 #include "content/common/media/video_capture.h" |
| 28 #include "media/video/capture/video_capture.h" | 28 #include "media/video/capture/video_capture.h" |
| 29 #include "media/video/capture/video_capture_device.h" | 29 #include "media/video/capture/video_capture_device.h" |
| 30 #include "media/video/capture/video_capture_types.h" | 30 #include "media/video/capture/video_capture_types.h" |
| 31 | 31 |
| 32 namespace media_stream { | 32 namespace media_stream { |
| 33 class VideoCaptureManager; | 33 class VideoCaptureManager; |
| 34 } // namespace media_stream | 34 } // namespace media_stream |
| 35 | 35 |
| 36 class VideoCaptureController | 36 class CONTENT_EXPORT VideoCaptureController |
| 37 : public base::RefCountedThreadSafe<VideoCaptureController>, | 37 : public base::RefCountedThreadSafe<VideoCaptureController>, |
| 38 public media::VideoCaptureDevice::EventHandler { | 38 public media::VideoCaptureDevice::EventHandler { |
| 39 public: | 39 public: |
| 40 VideoCaptureController( | 40 VideoCaptureController( |
| 41 media_stream::VideoCaptureManager* video_capture_manager); | 41 media_stream::VideoCaptureManager* video_capture_manager); |
| 42 | 42 |
| 43 // Start video capturing and try to use the resolution specified in | 43 // Start video capturing and try to use the resolution specified in |
| 44 // |params|. | 44 // |params|. |
| 45 // When capturing has started, the |event_handler| receives a call OnFrameInfo | 45 // When capturing has started, the |event_handler| receives a call OnFrameInfo |
| 46 // with resolution that best matches the requested that the video | 46 // with resolution that best matches the requested that the video |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 141 | 141 |
| 142 media_stream::VideoCaptureManager* video_capture_manager_; | 142 media_stream::VideoCaptureManager* video_capture_manager_; |
| 143 | 143 |
| 144 bool device_in_use_; | 144 bool device_in_use_; |
| 145 video_capture::State state_; | 145 video_capture::State state_; |
| 146 | 146 |
| 147 DISALLOW_IMPLICIT_CONSTRUCTORS(VideoCaptureController); | 147 DISALLOW_IMPLICIT_CONSTRUCTORS(VideoCaptureController); |
| 148 }; | 148 }; |
| 149 | 149 |
| 150 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_VIDEO_CAPTURE_CONTROLLER_H_ | 150 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_VIDEO_CAPTURE_CONTROLLER_H_ |
| OLD | NEW |