24 #ifndef _FIREVISION_CAMS_KINECT_H_ 25 #define _FIREVISION_CAMS_KINECT_H_ 29 #include <libfreenect.hpp> 31 namespace firevision {
33 class CameraArgumentParser;
41 void RGBCallback(freenect_pixel *rgb, uint32_t timestamp);
48 unsigned char *m_rgb_buffer;
49 uint16_t * m_depth_buffer;
51 uint32_t m_rgb_timestamp;
52 uint32_t m_depth_timestamp;
72 virtual unsigned char *
buffer();
87 Freenect::Freenect<FvFreenectDevice> *m_freenect_ctx;
93 unsigned int m_image_num;
95 unsigned char *m_buffer;
96 unsigned char *m_false_color_depth_buffer;
98 uint16_t m_gamma[2048];
Camera interface for image aquiring devices in FireVision.
Access the Microsoft Kinect camera using the freenect driver.
unsigned char * rgb_buffer()
Access the RGB buffer.
static const unsigned int FALSE_COLOR_DEPTH_IMAGE
False color depth image.
virtual void dispose_buffer()
Dispose current buffer.
virtual void set_image_number(unsigned int n)
Set image number to retrieve.
virtual bool ready()
Camera is ready for taking pictures.
Implementation of the FreenectDevice interface of the driver.
virtual void open()
Open the camera.
void DepthCallback(void *depth, uint32_t timestamp)
Callback function for the freenect driver.
virtual unsigned int buffer_size()
Size of buffer.
virtual void stop()
Stop image transfer from the camera.
uint16_t * depth_buffer()
Access the depth buffer.
virtual colorspace_t colorspace()
Colorspace of returned image.
void RGBCallback(freenect_pixel *rgb, uint32_t timestamp)
Callback function for the freenect driver.
KinectCamera(const CameraArgumentParser *cap=NULL)
Constructor.
virtual unsigned char * buffer()
Get access to current image buffer.
virtual void start()
Start image transfer from the camera.
virtual unsigned int pixel_height()
Height of image in pixels.
static const unsigned int RGB_IMAGE
Color image.
FvFreenectDevice(freenect_context *ctx, int index)
Constructor.
virtual void flush()
Flush image queue.
virtual unsigned int pixel_width()
Width of image in pixels.
~FvFreenectDevice()
Destructor.
virtual void print_info()
Print out camera information.
virtual void capture()
Capture an image.
virtual void close()
Close camera.
~KinectCamera()
Destructor.