49 using namespace boost;
54 OpenNIDevice::OpenNIDevice (xn::Context& context,
const xn::NodeInfo& device_node,
const xn::NodeInfo& image_node,
const xn::NodeInfo& depth_node,
const xn::NodeInfo& ir_node)
throw (
OpenNIException)
56 , device_node_info_ (device_node)
59 XnStatus
status = context_.CreateProductionTree (const_cast<xn::NodeInfo&>(depth_node));
60 if (status != XN_STATUS_OK)
63 status = context_.CreateProductionTree (const_cast<xn::NodeInfo&>(image_node));
64 if (status != XN_STATUS_OK)
67 status = context_.CreateProductionTree (const_cast<xn::NodeInfo&>(ir_node));
68 if (status != XN_STATUS_OK)
72 status = depth_node.GetInstance (depth_generator_);
73 if (status != XN_STATUS_OK)
74 THROW_OPENNI_EXCEPTION (
"creating depth generator instance failed. Reason: %s", xnGetStatusString (status));
76 status = image_node.GetInstance (image_generator_);
77 if (status != XN_STATUS_OK)
78 THROW_OPENNI_EXCEPTION (
"creating image generator instance failed. Reason: %s", xnGetStatusString (status));
80 status = ir_node.GetInstance (ir_generator_);
81 if (status != XN_STATUS_OK)
84 ir_generator_.RegisterToNewDataAvailable ((xn::StateChangedHandler)NewIRDataAvailable,
this, ir_callback_handle_);
86 depth_generator_.RegisterToNewDataAvailable ((xn::StateChangedHandler)NewDepthDataAvailable,
this, depth_callback_handle_);
87 image_generator_.RegisterToNewDataAvailable ((xn::StateChangedHandler)NewImageDataAvailable,
this, image_callback_handle_);
92 OpenNIDevice::OpenNIDevice (xn::Context& context,
const xn::NodeInfo& device_node,
const xn::NodeInfo& depth_node,
const xn::NodeInfo& ir_node)
throw (
OpenNIException)
94 , device_node_info_ (device_node)
97 XnStatus
status = context_.CreateProductionTree (const_cast<xn::NodeInfo&>(depth_node));
98 if (status != XN_STATUS_OK)
101 status = context_.CreateProductionTree (const_cast<xn::NodeInfo&>(ir_node));
102 if (status != XN_STATUS_OK)
106 status = depth_node.GetInstance (depth_generator_);
107 if (status != XN_STATUS_OK)
108 THROW_OPENNI_EXCEPTION (
"creating depth generator instance failed. Reason: %s", xnGetStatusString (status));
110 status = ir_node.GetInstance (ir_generator_);
111 if (status != XN_STATUS_OK)
114 ir_generator_.RegisterToNewDataAvailable ((xn::StateChangedHandler)NewIRDataAvailable,
this, ir_callback_handle_);
116 depth_generator_.RegisterToNewDataAvailable ((xn::StateChangedHandler)NewDepthDataAvailable,
this, depth_callback_handle_);
124 , device_node_info_ (0)
128 OpenNIDevice::~OpenNIDevice () throw ()
133 void OpenNIDevice::shutdown ()
137 boost::lock_guard<boost::mutex> image_guard(image_mutex_);
138 boost::lock_guard<boost::mutex> depth_guard(depth_mutex_);
139 boost::lock_guard<boost::mutex> ir_guard(ir_mutex_);
142 if (image_generator_.IsValid() && image_generator_.IsGenerating ())
143 image_generator_.StopGenerating ();
145 if (depth_generator_.IsValid () && depth_generator_.IsGenerating ())
146 depth_generator_.StopGenerating ();
148 if (ir_generator_.IsValid () && ir_generator_.IsGenerating ())
149 ir_generator_.StopGenerating ();
156 depth_condition_.notify_all ();
157 image_condition_.notify_all ();
158 ir_condition_.notify_all ();
159 data_threads_.join_all ();
168 if (hasDepthStream ())
170 unique_lock<mutex> depth_lock (depth_mutex_);
171 XnStatus
status = depth_generator_.GetRealProperty (
"ZPPS", pixel_size);
172 if (status != XN_STATUS_OK)
173 THROW_OPENNI_EXCEPTION (
"reading the pixel size of IR camera failed. Reason: %s", xnGetStatusString (status));
175 XnUInt64 depth_focal_length_SXGA;
176 status = depth_generator_.GetIntProperty (
"ZPD", depth_focal_length_SXGA);
177 if (status != XN_STATUS_OK)
178 THROW_OPENNI_EXCEPTION (
"reading the focal length of IR camera failed. Reason: %s", xnGetStatusString (status));
181 status = depth_generator_.GetRealProperty (
"LDDIS", baseline);
182 if (status != XN_STATUS_OK)
185 status = depth_generator_.GetIntProperty (
"ShadowValue", shadow_value_);
186 if (status != XN_STATUS_OK)
187 THROW_OPENNI_EXCEPTION (
"reading the value for pixels in shadow regions failed. Reason: %s", xnGetStatusString (status));
189 status = depth_generator_.GetIntProperty (
"NoSampleValue", no_sample_value_);
190 if (status != XN_STATUS_OK)
191 THROW_OPENNI_EXCEPTION (
"reading the value for pixels with no depth estimation failed. Reason: %s", xnGetStatusString (status));
194 baseline_ = (float)(baseline * 0.01);
197 depth_focal_length_SXGA_ = (float)depth_focal_length_SXGA / pixel_size;
199 data_threads_.create_thread (boost::bind (&OpenNIDevice::DepthDataThreadFunction,
this));
202 if (hasImageStream ())
204 lock_guard<mutex> image_lock (image_mutex_);
205 data_threads_.create_thread (boost::bind (&OpenNIDevice::ImageDataThreadFunction,
this));
210 lock_guard<mutex> ir_lock (ir_mutex_);
211 data_threads_.create_thread (boost::bind (&OpenNIDevice::IRDataThreadFunction,
this));
217 if (hasImageStream ())
219 lock_guard<mutex> image_lock (image_mutex_);
220 if (!image_generator_.IsGenerating ())
222 XnStatus
status = image_generator_.StartGenerating ();
223 if (status != XN_STATUS_OK)
233 if (hasImageStream ())
235 lock_guard<mutex> image_lock (image_mutex_);
236 if (image_generator_.IsGenerating ())
238 XnStatus
status = image_generator_.StopGenerating ();
239 if (status != XN_STATUS_OK)
249 if (hasDepthStream ())
251 lock_guard<mutex> depth_lock (depth_mutex_);
252 if (!depth_generator_.IsGenerating ())
254 XnStatus
status = depth_generator_.StartGenerating ();
256 if (status != XN_STATUS_OK)
266 if (hasDepthStream ())
268 lock_guard<mutex> depth_lock (depth_mutex_);
269 if (depth_generator_.IsGenerating ())
271 XnStatus
status = depth_generator_.StopGenerating ();
273 if (status != XN_STATUS_OK)
285 lock_guard<mutex> ir_lock (ir_mutex_);
286 if (!ir_generator_.IsGenerating ())
288 XnStatus
status = ir_generator_.StartGenerating ();
290 if (status != XN_STATUS_OK)
302 lock_guard<mutex> ir_lock (ir_mutex_);
303 if (ir_generator_.IsGenerating ())
305 XnStatus
status = ir_generator_.StopGenerating ();
307 if (status != XN_STATUS_OK)
317 lock_guard<mutex> image_lock (image_mutex_);
318 return ( image_generator_.IsValid () && image_generator_.IsGenerating ());
323 lock_guard<mutex> depth_lock (depth_mutex_);
324 return ( depth_generator_.IsValid () && depth_generator_.IsGenerating ());
329 lock_guard<mutex> ir_lock (ir_mutex_);
330 return ( ir_generator_.IsValid () && ir_generator_.IsGenerating ());
333 bool OpenNIDevice::hasImageStream ()
const throw ()
335 lock_guard<mutex> lock (image_mutex_);
336 return image_generator_.IsValid ();
340 bool OpenNIDevice::hasDepthStream ()
const throw ()
342 lock_guard<mutex> lock (depth_mutex_);
343 return depth_generator_.IsValid ();
347 bool OpenNIDevice::hasIRStream ()
const throw ()
349 lock_guard<mutex> ir_lock (ir_mutex_);
350 return ir_generator_.IsValid ();
355 if (hasDepthStream () && hasImageStream())
357 lock_guard<mutex> image_lock (image_mutex_);
358 lock_guard<mutex> depth_lock (depth_mutex_);
359 if (on_off && !depth_generator_.GetAlternativeViewPointCap ().IsViewPointAs (image_generator_))
361 if (depth_generator_.GetAlternativeViewPointCap ().IsViewPointSupported (image_generator_))
363 XnStatus
status = depth_generator_.GetAlternativeViewPointCap ().SetViewPoint (image_generator_);
364 if (status != XN_STATUS_OK)
372 XnStatus
status = depth_generator_.GetAlternativeViewPointCap ().ResetViewPoint ();
374 if (status != XN_STATUS_OK)
384 if (hasDepthStream () && hasImageStream() )
386 xn::DepthGenerator& depth_generator =
const_cast<xn::DepthGenerator&
>(depth_generator_);
387 xn::ImageGenerator& image_generator =
const_cast<xn::ImageGenerator&
>(image_generator_);
389 lock_guard<mutex> image_lock (image_mutex_);
390 lock_guard<mutex> depth_lock (depth_mutex_);
391 return (depth_generator.GetAlternativeViewPointCap ().IsViewPointAs (image_generator));
398 lock_guard<mutex> image_lock (image_mutex_);
399 lock_guard<mutex> depth_lock (depth_mutex_);
400 xn::ImageGenerator& image_generator =
const_cast<xn::ImageGenerator&
> (image_generator_);
401 return ( depth_generator_.IsValid() && image_generator_.IsValid() && depth_generator_.GetAlternativeViewPointCap().IsViewPointSupported(image_generator));
404 bool OpenNIDevice::isSynchronizationSupported ()
const throw ()
406 lock_guard<mutex> image_lock (image_mutex_);
407 lock_guard<mutex> depth_lock (depth_mutex_);
408 return ( depth_generator_.IsValid() && image_generator_.IsValid() && depth_generator_.IsCapabilitySupported (XN_CAPABILITY_FRAME_SYNC));
413 if (hasDepthStream () && hasImageStream())
415 lock_guard<mutex> image_lock (image_mutex_);
416 lock_guard<mutex> depth_lock (depth_mutex_);
419 if (on_off && !depth_generator_.GetFrameSyncCap ().IsFrameSyncedWith (image_generator_))
421 status = depth_generator_.GetFrameSyncCap ().FrameSyncWith (image_generator_);
422 if (status != XN_STATUS_OK)
423 THROW_OPENNI_EXCEPTION (
"could not turn on frame synchronization. Reason: %s", xnGetStatusString (status));
425 else if (!on_off && depth_generator_.GetFrameSyncCap ().IsFrameSyncedWith (image_generator_))
427 status = depth_generator_.GetFrameSyncCap ().StopFrameSyncWith (image_generator_);
428 if (status != XN_STATUS_OK)
429 THROW_OPENNI_EXCEPTION (
"could not turn off frame synchronization. Reason: %s", xnGetStatusString (status));
438 if (hasDepthStream () && hasImageStream())
440 lock_guard<mutex> image_lock (image_mutex_);
441 lock_guard<mutex> depth_lock (depth_mutex_);
442 xn::DepthGenerator& depth_generator =
const_cast<xn::DepthGenerator&
>(depth_generator_);
443 xn::ImageGenerator& image_generator =
const_cast<xn::ImageGenerator&
>(image_generator_);
444 return (depth_generator.GetFrameSyncCap ().CanFrameSyncWith (image_generator) && depth_generator.GetFrameSyncCap ().IsFrameSyncedWith (image_generator));
450 bool OpenNIDevice::isDepthCroppingSupported ()
const throw ()
452 lock_guard<mutex> depth_lock (depth_mutex_);
453 return ( image_generator_.IsValid() && depth_generator_.IsCapabilitySupported (XN_CAPABILITY_CROPPING) );
458 if (hasDepthStream ())
460 lock_guard<mutex> depth_lock (depth_mutex_);
462 xn::DepthGenerator& depth_generator =
const_cast<xn::DepthGenerator&
>(depth_generator_);
463 XnStatus
status = depth_generator.GetCroppingCap ().GetCropping (cropping);
464 if (status != XN_STATUS_OK)
465 THROW_OPENNI_EXCEPTION (
"could not read cropping information for depth stream. Reason: %s", xnGetStatusString (status));
467 return cropping.bEnabled;
472 void OpenNIDevice::setDepthCropping (
unsigned x,
unsigned y,
unsigned width,
unsigned height)
throw (
OpenNIException)
474 if (hasDepthStream ())
476 lock_guard<mutex> depth_lock (depth_mutex_);
478 cropping.nXOffset = x;
479 cropping.nYOffset = y;
480 cropping.nXSize = width;
481 cropping.nYSize = height;
483 cropping.bEnabled = (width != 0 && height != 0);
484 XnStatus
status = depth_generator_.GetCroppingCap ().SetCropping (cropping);
485 if (status != XN_STATUS_OK)
486 THROW_OPENNI_EXCEPTION (
"could not set cropping information for depth stream. Reason: %s", xnGetStatusString (status));
497 unique_lock<mutex> image_lock (image_mutex_);
500 image_condition_.wait (image_lock);
504 image_generator_.WaitAndUpdateData ();
505 xn::ImageMetaData image_md;
506 image_generator_.GetMetaData (image_md);
508 XnStatus xs = image_data->CopyFrom (image_md);
509 image_lock.unlock ();
511 if (xs != XN_STATUS_OK)
515 for (map< OpenNIDevice::CallbackHandle, ActualImageCallbackFunction >::iterator callbackIt = image_callback_.begin (); callbackIt != image_callback_.end (); ++callbackIt)
517 callbackIt->second.operator()(image);
527 unique_lock<mutex> depth_lock (depth_mutex_);
530 depth_condition_.wait (depth_lock);
534 depth_generator_.WaitAndUpdateData ();
535 xn::DepthMetaData image_md;
536 depth_generator_.GetMetaData (image_md);
538 XnStatus xs = depth_data->CopyFrom (image_md);
539 depth_lock.unlock ();
541 if (xs != XN_STATUS_OK)
546 for (map< OpenNIDevice::CallbackHandle, ActualDepthImageCallbackFunction >::iterator callbackIt = depth_callback_.begin ();
547 callbackIt != depth_callback_.end (); ++callbackIt)
549 callbackIt->second.operator()(depth_image);
559 unique_lock<mutex> ir_lock (ir_mutex_);
562 ir_condition_.wait (ir_lock);
566 ir_generator_.WaitAndUpdateData ();
567 xn::IRMetaData image_md;
568 ir_generator_.GetMetaData (image_md);
570 XnStatus xs = ir_data->CopyFrom (image_md);
573 if (xs != XN_STATUS_OK)
578 for (map< OpenNIDevice::CallbackHandle, ActualIRImageCallbackFunction >::iterator callbackIt = ir_callback_.begin ();
579 callbackIt != ir_callback_.end (); ++callbackIt)
581 callbackIt->second.operator()(ir_image);
586 void __stdcall OpenNIDevice::NewDepthDataAvailable (xn::ProductionNode& node,
void* cookie)
throw ()
592 void __stdcall OpenNIDevice::NewImageDataAvailable (xn::ProductionNode& node,
void* cookie)
throw ()
598 void __stdcall OpenNIDevice::NewIRDataAvailable (xn::ProductionNode& node,
void* cookie)
throw ()
606 if (!hasImageStream ())
609 image_callback_[image_callback_handle_counter_] = boost::bind (
callback, _1, custom_data);
610 return image_callback_handle_counter_++;
615 if (!hasImageStream ())
618 return (image_callback_.erase (callbackHandle) != 0);
623 if (!hasDepthStream ())
626 depth_callback_[depth_callback_handle_counter_] = boost::bind (
callback, _1, custom_data);
627 return depth_callback_handle_counter_++;
632 if (hasDepthStream ())
633 return (depth_callback_.erase (callbackHandle) != 0);
641 if (!hasDepthStream ())
644 ir_callback_[ir_callback_handle_counter_] = boost::bind (
callback, _1, custom_data);
645 return ir_callback_handle_counter_++;
650 if (!hasDepthStream ())
653 return (ir_callback_.erase (callbackHandle) != 0);
656 const char* OpenNIDevice::getSerialNumber () throw ()
658 const char* openni_serial = device_node_info_.GetInstanceName ();
659 if (strlen(openni_serial)>0 && strcmp(openni_serial,
"Device1")) {
660 return openni_serial;
662 char *primesense_serial = (
char*)malloc(XN_MAX_NAME_LENGTH);
663 context_.CreateProductionTree(device_node_info_);
666 if(device_node_info_.GetInstance(device) != XN_STATUS_OK) {
670 xn::DeviceIdentificationCapability d = device.GetIdentificationCap();
672 d.GetSerialNumber(primesense_serial,XN_MAX_NAME_LENGTH);
675 return primesense_serial;
679 const char* OpenNIDevice::getConnectionString ()
const throw ()
681 return device_node_info_.GetCreationInfo ();
684 unsigned short OpenNIDevice::getVendorID ()
const throw ()
686 unsigned short vendor_id;
687 unsigned short product_id;
691 unsigned char address;
693 sscanf (device_node_info_.GetCreationInfo(),
"%hx/%hx@%hhu/%hhu", &vendor_id, &product_id, &bus, &address);
696 OpenNIDriver::getDeviceType (device_node_info_.GetCreationInfo(), vendor_id, product_id);
701 unsigned short OpenNIDevice::getProductID ()
const throw ()
703 unsigned short vendor_id;
704 unsigned short product_id;
707 unsigned char address;
708 sscanf (device_node_info_.GetCreationInfo(),
"%hx/%hx@%hhu/%hhu", &vendor_id, &product_id, &bus, &address);
711 OpenNIDriver::getDeviceType (device_node_info_.GetCreationInfo(), vendor_id, product_id);
716 unsigned char OpenNIDevice::getBus ()
const throw ()
718 unsigned char bus = 0;
720 unsigned short vendor_id;
721 unsigned short product_id;
722 unsigned char address;
723 sscanf (device_node_info_.GetCreationInfo(),
"%hx/%hx@%hhu/%hhu", &vendor_id, &product_id, &bus, &address);
728 unsigned char OpenNIDevice::getAddress ()
const throw ()
730 unsigned char address = 0;
732 unsigned short vendor_id;
733 unsigned short product_id;
735 sscanf (device_node_info_.GetCreationInfo(),
"%hx/%hx@%hhu/%hhu", &vendor_id, &product_id, &bus, &address);
740 const char* OpenNIDevice::getVendorName ()
const throw ()
742 XnProductionNodeDescription& description =
const_cast<XnProductionNodeDescription&
>(device_node_info_.GetDescription ());
743 return description.strVendor;
746 const char* OpenNIDevice::getProductName ()
const throw ()
748 XnProductionNodeDescription& description =
const_cast<XnProductionNodeDescription&
>(device_node_info_.GetDescription ());
749 return description.strName;
752 bool OpenNIDevice::findCompatibleImageMode (
const XnMapOutputMode& output_mode, XnMapOutputMode& mode)
const throw (
OpenNIException)
754 if (isImageModeSupported (output_mode))
762 for (vector<XnMapOutputMode>::const_iterator modeIt = available_image_modes_.begin (); modeIt != available_image_modes_.end (); ++modeIt)
764 if (modeIt->nFPS == output_mode.nFPS && isImageResizeSupported (modeIt->nXRes, modeIt->nYRes, output_mode.nXRes, output_mode.nYRes))
768 if (mode.nXRes * mode.nYRes > modeIt->nXRes * modeIt->nYRes )
782 bool OpenNIDevice::findCompatibleDepthMode (
const XnMapOutputMode& output_mode, XnMapOutputMode& mode)
const throw (
OpenNIException)
784 if (isDepthModeSupported (output_mode))
792 for (vector<XnMapOutputMode>::const_iterator modeIt = available_depth_modes_.begin (); modeIt != available_depth_modes_.end (); ++modeIt)
794 if (modeIt->nFPS == output_mode.nFPS && isImageResizeSupported (modeIt->nXRes, modeIt->nYRes, output_mode.nXRes, output_mode.nYRes))
798 if (mode.nXRes * mode.nYRes > modeIt->nXRes * modeIt->nYRes )
850 bool OpenNIDevice::isImageModeSupported (
const XnMapOutputMode& output_mode)
const throw (
OpenNIException)
852 for (vector<XnMapOutputMode>::const_iterator modeIt = available_image_modes_.begin (); modeIt != available_image_modes_.end (); ++modeIt)
854 if (modeIt->nFPS == output_mode.nFPS && modeIt->nXRes == output_mode.nXRes && modeIt->nYRes == output_mode.nYRes)
860 bool OpenNIDevice::isDepthModeSupported (
const XnMapOutputMode& output_mode)
const throw (
OpenNIException)
862 for (vector<XnMapOutputMode>::const_iterator modeIt = available_depth_modes_.begin (); modeIt != available_depth_modes_.end (); ++modeIt)
864 if (modeIt->nFPS == output_mode.nFPS && modeIt->nXRes == output_mode.nXRes && modeIt->nYRes == output_mode.nYRes)
870 const XnMapOutputMode& OpenNIDevice::getDefaultImageMode ()
const throw ()
872 return available_image_modes_[0];
875 const XnMapOutputMode& OpenNIDevice::getDefaultDepthMode ()
const throw ()
877 return available_depth_modes_[0];
880 const XnMapOutputMode& OpenNIDevice::getDefaultIRMode ()
const throw ()
883 return available_depth_modes_[0];
886 void OpenNIDevice::setImageOutputMode (
const XnMapOutputMode& output_mode)
throw (
OpenNIException)
888 if (hasImageStream ())
890 lock_guard<mutex> image_lock (image_mutex_);
891 XnStatus
status = image_generator_.SetMapOutputMode (output_mode);
892 if (status != XN_STATUS_OK)
893 THROW_OPENNI_EXCEPTION (
"Could not set image stream output mode to %dx%d@%d. Reason: %s", output_mode.nXRes, output_mode.nYRes, output_mode.nFPS, xnGetStatusString (status));
899 void OpenNIDevice::setDepthOutputMode (
const XnMapOutputMode& output_mode)
throw (
OpenNIException)
901 if (hasDepthStream ())
903 lock_guard<mutex> depth_lock (depth_mutex_);
904 XnStatus
status = depth_generator_.SetMapOutputMode (output_mode);
905 if (status != XN_STATUS_OK)
906 THROW_OPENNI_EXCEPTION (
"Could not set depth stream output mode to %dx%d@%d. Reason: %s", output_mode.nXRes, output_mode.nYRes, output_mode.nFPS, xnGetStatusString (status));
912 void OpenNIDevice::setIROutputMode (
const XnMapOutputMode& output_mode)
throw (
OpenNIException)
916 lock_guard<mutex> ir_lock (ir_mutex_);
917 XnStatus
status = ir_generator_.SetMapOutputMode (output_mode);
918 if (status != XN_STATUS_OK)
919 THROW_OPENNI_EXCEPTION (
"Could not set IR stream output mode to %dx%d@%d. Reason: %s", output_mode.nXRes, output_mode.nYRes, output_mode.nFPS, xnGetStatusString (status));
927 if (!hasImageStream ())
930 XnMapOutputMode output_mode;
931 lock_guard<mutex> image_lock (image_mutex_);
932 XnStatus
status = image_generator_.GetMapOutputMode (output_mode);
933 if (status != XN_STATUS_OK)
934 THROW_OPENNI_EXCEPTION (
"Could not get image stream output mode. Reason: %s", xnGetStatusString (status));
940 if (!hasDepthStream () )
943 XnMapOutputMode output_mode;
944 lock_guard<mutex> depth_lock (depth_mutex_);
945 XnStatus
status = depth_generator_.GetMapOutputMode (output_mode);
946 if (status != XN_STATUS_OK)
947 THROW_OPENNI_EXCEPTION (
"Could not get depth stream output mode. Reason: %s", xnGetStatusString (status));
956 XnMapOutputMode output_mode;
957 lock_guard<mutex> ir_lock (ir_mutex_);
958 XnStatus
status = ir_generator_.GetMapOutputMode (output_mode);
959 if (status != XN_STATUS_OK)
965 const float OpenNIDevice::rgb_focal_length_SXGA_ = 1050;
void notify_all() BOOST_NOEXCEPT
#define THROW_OPENNI_EXCEPTION(format,...)
boost::condition_variable depth_condition_
boost::function< void(boost::shared_ptr< IRImage >, void *cookie) > IRImageCallbackFunction
boost::condition_variable ir_condition_
boost::condition_variable image_condition_
boost::function< void(boost::shared_ptr< DepthImage >, void *cookie) > DepthImageCallbackFunction
boost::function< void(boost::shared_ptr< Image >, void *cookie) > ImageCallbackFunction
Class representing an astract device for Primesense or MS Kinect devices.
This class provides methods to fill a depth or disparity image.
Class containing just a reference to IR meta data.