40 #include <pxcsession.h>
41 #include <pxccapture.h>
42 #include <pxccapturemanager.h>
45 #include <pcl/pcl_exports.h>
47 #include <boost/core/noncopyable.hpp>
57 class RealSenseGrabber;
72 using Ptr = std::shared_ptr<RealSenseDeviceManager>;
80 std::lock_guard<std::mutex> lock (mutex_);
90 return (device_list_.size ());
93 std::shared_ptr<RealSenseDevice>
96 std::shared_ptr<RealSenseDevice>
99 std::shared_ptr<RealSenseDevice>
111 weak_ptr<RealSenseDevice> device_ptr;
112 inline bool isCaptured () {
return (!device_ptr.expired ()); }
116 std::shared_ptr<RealSenseDevice>
117 capture (DeviceInfo& device_info);
122 populateDeviceList ();
124 std::shared_ptr<PXCSession> session_;
125 std::shared_ptr<PXCCaptureManager> capture_manager_;
127 std::vector<DeviceInfo> device_list_;
129 static std::mutex mutex_;
137 using Ptr = pcl::shared_ptr<RealSenseDevice>;
139 inline const std::string&
142 inline PXCCapture::Device&
149 std::string
id = device->getSerialNumber ();
158 std::string device_id_;
159 std::shared_ptr<PXCCapture> capture_;
160 std::shared_ptr<PXCCapture::Device> device_;
static void reset(RealSenseDevice::Ptr &device)
Reset the state of given device by releasing and capturing again.
PXCCapture::Device & getPXCDevice()
const std::string & getSerialNumber()
pcl::shared_ptr< RealSenseDevice > Ptr
std::shared_ptr< RealSenseDevice > captureDevice(const std::string &sn)
std::shared_ptr< RealSenseDevice > captureDevice(std::size_t index)
std::shared_ptr< RealSenseDevice > captureDevice()
static Ptr & getInstance()
std::size_t getNumDevices()
~RealSenseDeviceManager()
std::shared_ptr< RealSenseDeviceManager > Ptr
Defines functions, macros and traits for allocating and using memory.