Skip to content

folkcode/structure_grabber

 
 

Repository files navigation

#structure_grabber

Grabber for Structure Sensor (Depth and Infrared) using OpenNI2 (optionally, OpenCV and PointCloudLibrary)

##Requirement

Usage

Preparation

  1. Create the project by cmake

Basic

  1. Include "structure_grabber.h".
  2. To start, write:
StructureGrabber grabber;
grabber.open();
  1. To capture, write:
grabber.acquire();
  1. To get raw data, write:
unsigned short *depth_data, *infrared_data;
grabber.copyDepthDataTo(depth_data);
grabber.copyInfraredDataTo(infrared_data);

With OpenCV

  1. Include OpenCV headers before including "structure_grabber.h".
  2. To get IplImage or cv::Mat, write:
cv::Mat depth_image, infrared_image;
grabber.acquire();
grabber.copyDepthImageTo(depth_image);
grabber.copyInfraredImageTo(infrared_image)

With PCL

  1. Include PCL headers before including "structure_grabber.h".
  2. To get pcl::PointCloud, write:
pcl::PointCloud<pcl::PointXYZ> cloud;
grabber.acquire();
grabber.copyPointCloudTo(cloud);

© 2014 kenken.

About

Grabber for Structure Sensor (Depth and Infrared) using OpenNI2 (optionally, OpenCV and PCL)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 94.2%
  • CMake 5.8%