Using the JointTrackingState
enum on each of the joints will allow you to determine if a particular Joint
is being tracked or not.
For example: skeleton.Joints[JointID.HandRight].TrackingState
will tell you if the joint is:
- Tracked: The joint is actively being tracked by the SDK and is returning data that can be trusted.
- Inferred: The SDK is not confident on where the joint is, but can make an educated guess.
- NotTracked: The joint is not being tracked and no data is available.
You can cycle through each of the joints and check their status. Based on if it is Tracked
, Inferred
or NotTracked
you can take appropriate action.
The "Skeleton Basics" example in the Kinect for Windows Developer Toolkit demonstrates how to adjust a drawn skeleton based on these values.