summaryrefslogtreecommitdiffhomepage
path: root/video-ps3eye/module.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2019-09-22 16:51:23 +0200
committerStanislaw Halik <sthalik@misaki.pl>2019-09-22 16:51:51 +0200
commit4cb73ce5853d924c17381f3183226b8835172da7 (patch)
tree8670106bf6b216d7397bff0b104c7d1a4563f244 /video-ps3eye/module.cpp
parentc8fb7bfa37555e5cbe68f368ebb98b161fb2771a (diff)
video/ps3eye: buffer flush
Diffstat (limited to 'video-ps3eye/module.cpp')
-rw-r--r--video-ps3eye/module.cpp33
1 files changed, 32 insertions, 1 deletions
diff --git a/video-ps3eye/module.cpp b/video-ps3eye/module.cpp
index b04c6acb..ac6d8807 100644
--- a/video-ps3eye/module.cpp
+++ b/video-ps3eye/module.cpp
@@ -1,5 +1,5 @@
#include "module.hpp"
-
+#if 0
#include <libusb.h>
int device_count()
@@ -48,3 +48,34 @@ bool check_device_exists()
return ret;
}
+static const QString camera_name = QStringLiteral("PS3 Eye open driver");
+
+namespace video::impl {
+
+std::vector<QString> ps3eye_camera_::camera_names() const
+{
+ if (check_device_exists())
+ return { camera_name };
+ else
+ return {};
+}
+std::unique_ptr<camera> ps3eye_camera_::make_camera(const QString& name)
+{
+ if (name == camera_name && check_device_exists())
+ return std::make_unique<ps3eye_camera>();
+ else
+ return {};
+}
+bool ps3eye_camera_::show_dialog(const QString& camera_name)
+{
+ // TODO
+ return false;
+}
+bool ps3eye_camera_::can_show_dialog(const QString& camera_name)
+{
+ return false;
+}
+
+} // ns video::impl
+
+#endif