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

Unified Diff: media/video/capture/win/video_capture_device_factory_win.h

Issue 276383002: VideoCaptureDeviceWin: Extract class-static method into a Factory (both MF/DS) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased factory win. Created 6 years, 7 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: media/video/capture/win/video_capture_device_factory_win.h
diff --git a/media/video/capture/mac/video_capture_device_factory_mac.h b/media/video/capture/win/video_capture_device_factory_win.h
similarity index 56%
copy from media/video/capture/mac/video_capture_device_factory_mac.h
copy to media/video/capture/win/video_capture_device_factory_win.h
index a3f26fdede9b629c92ff985aaf3969c17c5264ea..187850f54765e36f946cbcb280922e3e04f73ca3 100644
--- a/media/video/capture/mac/video_capture_device_factory_mac.h
+++ b/media/video/capture/win/video_capture_device_factory_win.h
@@ -2,21 +2,24 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Implementation of a VideoCaptureDeviceFactory class for Mac.
+// Implementation of a VideoCaptureDeviceFactory class for Windows platforms.
-#ifndef MEDIA_VIDEO_CAPTURE_VIDEO_CAPTURE_DEVICE_FACTORY_MAC_H_
-#define MEDIA_VIDEO_CAPTURE_VIDEO_CAPTURE_DEVICE_FACTORY_MAC_H_
+#ifndef MEDIA_VIDEO_CAPTURE_VIDEO_CAPTURE_DEVICE_FACTORY_WIN_H_
+#define MEDIA_VIDEO_CAPTURE_VIDEO_CAPTURE_DEVICE_FACTORY_WIN_H_
#include "media/video/capture/video_capture_device_factory.h"
namespace media {
-// Extension of VideoCaptureDeviceFactory to create and manipulate Mac devices.
-class MEDIA_EXPORT VideoCaptureDeviceFactoryMac :
+// Extension of VideoCaptureDeviceFactory to create and manipulate Windows
+// devices, via either DirectShow or MediaFoundation APIs.
+class MEDIA_EXPORT VideoCaptureDeviceFactoryWin :
public VideoCaptureDeviceFactory {
public:
- VideoCaptureDeviceFactoryMac();
- virtual ~VideoCaptureDeviceFactoryMac() {}
+ static bool PlatformSupportsMediaFoundation();
+
+ VideoCaptureDeviceFactoryWin();
+ virtual ~VideoCaptureDeviceFactoryWin() {}
virtual scoped_ptr<VideoCaptureDevice> Create(
scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner,
@@ -27,9 +30,11 @@ class MEDIA_EXPORT VideoCaptureDeviceFactoryMac :
VideoCaptureFormats* supported_formats) OVERRIDE;
private:
- DISALLOW_COPY_AND_ASSIGN(VideoCaptureDeviceFactoryMac);
+ bool use_media_foundation_;
+
+ DISALLOW_COPY_AND_ASSIGN(VideoCaptureDeviceFactoryWin);
};
} // namespace media
-#endif // MEDIA_VIDEO_CAPTURE_VIDEO_CAPTURE_DEVICE_FACTORY_MAC_H_
+#endif // MEDIA_VIDEO_CAPTURE_VIDEO_CAPTURE_DEVICE_FACTORY_WIN_H_
« no previous file with comments | « media/video/capture/video_capture_device_unittest.cc ('k') | media/video/capture/win/video_capture_device_factory_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698