RandomBallCover  1.2.1
 Hosted by GitHub
Public Member Functions | List of all members
MyFreenectDevice Class Reference

A class that extends Freenect::FreenectDevice by defining the VideoCallback function so we can be getting updates with the latest RGB frame. More...

Inheritance diagram for MyFreenectDevice:
Inheritance graph
[legend]
Collaboration diagram for MyFreenectDevice:
Collaboration graph
[legend]

Public Member Functions

 MyFreenectDevice (freenect_context *ctx, int idx)
 
void VideoCallback (void *rgb, uint32_t timestamp)
 Delivers the latest RGB frame. More...
 
void DepthCallback (void *depth, uint32_t timestamp)
 Delivers the latest Depth frame. More...
 
bool updateFrames (std::vector< uint8_t > &rgb, std::vector< uint16_t > &depth)
 Retrieves the most recently received RGB and Depth frames. More...
 

Detailed Description

A class that extends Freenect::FreenectDevice by defining the VideoCallback function so we can be getting updates with the latest RGB frame.

Constructor & Destructor Documentation

MyFreenectDevice::MyFreenectDevice ( freenect_context *  ctx,
int  idx 
)
inline
Note
The creation of the device is done through the Freenect class.
Parameters
[in]ctxcontext to open device through (handled by the library).
[in]idxindex of the device on the bus.

Member Function Documentation

void MyFreenectDevice::DepthCallback ( void *  depth,
uint32_t  timestamp 
)
inline

Delivers the latest Depth frame.

Note
Do not call directly, it's only used by the library.
Parameters
[in]depthan array holding the depth frame.
[in]timestampa time stamp.
bool MyFreenectDevice::updateFrames ( std::vector< uint8_t > &  rgb,
std::vector< uint16_t > &  depth 
)
inline

Retrieves the most recently received RGB and Depth frames.

Returns
A flag to indicate whether new frames were present.
void MyFreenectDevice::VideoCallback ( void *  rgb,
uint32_t  timestamp 
)
inline

Delivers the latest RGB frame.

Note
Do not call directly, it's only used by the library.
Parameters
[in]rgban array holding the rgb frame.
[in]timestampa time stamp.

The documentation for this class was generated from the following file: