| // Copyright 2014 The Chromium Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| |
| // Implementation of a VideoCaptureDeviceFactoryLinux class. |
| |
| #ifndef MEDIA_CAPTURE_VIDEO_LINUX_VIDEO_CAPTURE_DEVICE_FACTORY_LINUX_H_ |
| #define MEDIA_CAPTURE_VIDEO_LINUX_VIDEO_CAPTURE_DEVICE_FACTORY_LINUX_H_ |
| |
| #include "media/capture/video/video_capture_device_factory.h" |
| |
| #include "base/macros.h" |
| #include "media/base/video_capture_types.h" |
| |
| namespace media { |
| |
| // Extension of VideoCaptureDeviceFactory to create and manipulate Linux |
| // devices. |
| class CAPTURE_EXPORT VideoCaptureDeviceFactoryLinux |
| : public VideoCaptureDeviceFactory { |
| public: |
| explicit VideoCaptureDeviceFactoryLinux( |
| scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner); |
| ~VideoCaptureDeviceFactoryLinux() override; |
| |
| std::unique_ptr<VideoCaptureDevice> Create( |
| const VideoCaptureDevice::Name& device_name) override; |
| void GetDeviceNames(VideoCaptureDevice::Names* device_names) override; |
| void GetDeviceSupportedFormats( |
| const VideoCaptureDevice::Name& device, |
| VideoCaptureFormats* supported_formats) override; |
| |
| private: |
| scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner_; |
| DISALLOW_COPY_AND_ASSIGN(VideoCaptureDeviceFactoryLinux); |
| }; |
| |
| } // namespace media |
| #endif // MEDIA_CAPTURE_VIDEO_LINUX_VIDEO_CAPTURE_DEVICE_FACTORY_LINUX_H_ |