![]() |
NiTE 2.0
|
#include <NiTE.h>
Classes | |
class | Listener |
Public Member Functions | |
HandTracker () | |
~HandTracker () | |
void | addListener (Listener *pListener) |
Status | convertDepthCoordinatesToHand (int x, int y, int z, float *pOutX, float *pOutY) const |
Status | convertHandCoordinatesToDepth (float x, float y, float z, float *pOutX, float *pOutY) const |
Status | create (openni::Device *pDevice=NULL) |
void | destroy () |
float | getSmoothingFactor () const |
bool | isValid () const |
Status | readFrame (HandTrackerFrameRef *pFrame) |
void | removeListener (Listener *pListener) |
Status | setSmoothingFactor (float factor) |
Status | startGestureDetection (GestureType type) |
Status | startHandTracking (const Point3f &position, HandId *pNewHandId) |
void | stopGestureDetection (GestureType type) |
void | stopHandTracking (HandId id) |
This is the main object of the Hand Tracker algorithm. Through it all the hands and gestures are accessible.
nite::HandTracker::HandTracker | ( | ) | [inline] |
nite::HandTracker::~HandTracker | ( | ) | [inline] |
void nite::HandTracker::addListener | ( | Listener * | pListener | ) | [inline] |
Status nite::HandTracker::convertDepthCoordinatesToHand | ( | int | x, |
int | y, | ||
int | z, | ||
float * | pOutX, | ||
float * | pOutY | ||
) | const [inline] |
Hand position is provided in a different set of coordinates than the depth coordinates. While the depth coordinates are projective, the hand and gestures are provided in real world coordinates, i.e. number of millimeters from the sensor. This function enables conversion from the depth coordinates to the hand coordinates. This is useful, for instance, to allow measurements.
Status nite::HandTracker::convertHandCoordinatesToDepth | ( | float | x, |
float | y, | ||
float | z, | ||
float * | pOutX, | ||
float * | pOutY | ||
) | const [inline] |
Hand position is provided in a different set of coordinates than the depth coordinates. While the depth coordinates are projective, the hand and gestures are provided in real world coordinates, i.e. number of millimeters from the sensor. This function enables conversion from the hand coordinates to the depth coordinates. This is useful, for instance, to match the hand to the depth.
Status nite::HandTracker::create | ( | openni::Device * | pDevice = NULL | ) | [inline] |
void nite::HandTracker::destroy | ( | ) | [inline] |
float nite::HandTracker::getSmoothingFactor | ( | ) | const [inline] |
bool nite::HandTracker::isValid | ( | ) | const [inline] |
Status nite::HandTracker::readFrame | ( | HandTrackerFrameRef * | pFrame | ) | [inline] |
Get the next snapshot of the algorithm
void nite::HandTracker::removeListener | ( | Listener * | pListener | ) | [inline] |
Status nite::HandTracker::setSmoothingFactor | ( | float | factor | ) | [inline] |
Control the smoothing factor of the skeleton joints
Status nite::HandTracker::startGestureDetection | ( | GestureType | type | ) | [inline] |
Start detecting a specific gesture
Status nite::HandTracker::startHandTracking | ( | const Point3f & | position, |
HandId * | pNewHandId | ||
) | [inline] |
Request a hand in a specific position, assuming there really is a hand there. For instance, the position received from a gesture can be used.
void nite::HandTracker::stopGestureDetection | ( | GestureType | type | ) | [inline] |
Stop detecting a specific gesture
void nite::HandTracker::stopHandTracking | ( | HandId | id | ) | [inline] |
Inform the algorithm that a specific hand is no longer required