diff options
Diffstat (limited to 'video-ps3eye/PS3EYEDriver/singleton.hpp')
-rw-r--r-- | video-ps3eye/PS3EYEDriver/singleton.hpp | 32 |
1 files changed, 0 insertions, 32 deletions
diff --git a/video-ps3eye/PS3EYEDriver/singleton.hpp b/video-ps3eye/PS3EYEDriver/singleton.hpp deleted file mode 100644 index 7e8dc23c..00000000 --- a/video-ps3eye/PS3EYEDriver/singleton.hpp +++ /dev/null @@ -1,32 +0,0 @@ -#pragma once - -#include <vector> -#include <memory> -#include <thread> -#include <atomic> - -struct libusb_context; -struct ps3eye_camera; - -struct USBMgr -{ - USBMgr(); - ~USBMgr(); - USBMgr(const USBMgr&) = delete; - void operator=(const USBMgr&) = delete; - - static USBMgr& instance(); - int list_devices(std::vector<std::shared_ptr<ps3eye_camera>>& list); - void camera_started(); - void camera_stopped(); - -private: - libusb_context* usb_context = nullptr; - std::thread update_thread; - std::atomic_int active_camera_count = 0; - std::atomic_bool exit_signaled = false; - - void start_xfer_thread(); - void stop_xfer_thread(); - void transfer_loop(); -}; |