libfreenect2  0.2
Classes | Public Member Functions | Static Public Attributes | List of all members
Freenect2Device Class Referenceabstract

Device control. More...

#include <libfreenect2/libfreenect2.hpp>

Classes

struct  ColorCameraParams
 Color camera calibration parameters. More...
 
struct  Config
 Configuration of depth processing. More...
 
struct  IrCameraParams
 IR camera intrinsic calibration parameters. More...
 

Public Member Functions

virtual ~Freenect2Device ()
 
virtual std::string getSerialNumber ()=0
 
virtual std::string getFirmwareVersion ()=0
 
virtual ColorCameraParams getColorCameraParams ()=0
 Get current color parameters. More...
 
virtual IrCameraParams getIrCameraParams ()=0
 Get current depth parameters. More...
 
virtual void setColorCameraParams (const ColorCameraParams &params)=0
 Replace factory preset color camera parameters. More...
 
virtual void setIrCameraParams (const IrCameraParams &params)=0
 Replace factory preset depth camera parameters. More...
 
virtual void setConfiguration (const Config &config)=0
 Configure depth processing. More...
 
virtual void setColorFrameListener (FrameListener *rgb_frame_listener)=0
 Provide your listener to receive color frames. More...
 
virtual void setIrAndDepthFrameListener (FrameListener *ir_frame_listener)=0
 Provide your listener to receive IR and depth frames. More...
 
virtual bool start ()=0
 Start data processing with both RGB and depth streams. More...
 
virtual bool startStreams (bool rgb, bool depth)=0
 Start data processing with or without some streams. More...
 
virtual bool stop ()=0
 Stop data processing. More...
 
virtual bool close ()=0
 Shut down the device. More...
 

Static Public Attributes

static const unsigned int VendorId = 0x045E
 
static const unsigned int ProductId = 0x02D8
 
static const unsigned int ProductIdPreview = 0x02C4
 

Detailed Description

Device control.

Constructor & Destructor Documentation

virtual ~Freenect2Device ( )
virtual

Member Function Documentation

virtual std::string getSerialNumber ( )
pure virtual
virtual std::string getFirmwareVersion ( )
pure virtual
virtual ColorCameraParams getColorCameraParams ( )
pure virtual

Get current color parameters.

Kinect v2 includes factory preset values for these parameters. They are used in Registration.

virtual IrCameraParams getIrCameraParams ( )
pure virtual

Get current depth parameters.

Kinect v2 includes factory preset values for these parameters. They are used in depth image decoding, and Registration.

virtual void setColorCameraParams ( const ColorCameraParams params)
pure virtual

Replace factory preset color camera parameters.

We do not have a clear understanding of the meaning of the parameters right now. You probably want to leave it as it is.

virtual void setIrCameraParams ( const IrCameraParams params)
pure virtual

Replace factory preset depth camera parameters.

This decides accuracy in depth images. You are recommended to provide calibrated values.

virtual void setConfiguration ( const Config config)
pure virtual

Configure depth processing.

virtual void setColorFrameListener ( FrameListener rgb_frame_listener)
pure virtual

Provide your listener to receive color frames.

virtual void setIrAndDepthFrameListener ( FrameListener ir_frame_listener)
pure virtual

Provide your listener to receive IR and depth frames.

virtual bool start ( )
pure virtual

Start data processing with both RGB and depth streams.

All above configuration must only be called before start() or after stop().

FrameListener will receive frames when the device is running.

Returns
true if ok, false if error.
virtual bool startStreams ( bool  rgb,
bool  depth 
)
pure virtual

Start data processing with or without some streams.

FrameListener will receive enabled frames when the device is running.

Parameters
rgbWhether to enable RGB stream.
depthWhether to enable depth stream.
Returns
true if ok, false if error.
virtual bool stop ( )
pure virtual

Stop data processing.

Returns
true if ok, false if error.
virtual bool close ( )
pure virtual

Shut down the device.

Returns
true if ok, false if error.

Member Data Documentation

const unsigned int VendorId = 0x045E
static
const unsigned int ProductId = 0x02D8
static
const unsigned int ProductIdPreview = 0x02C4
static