Painting a skeleton
- Posted: Apr 18, 2012 at 6:00AM
- 6,266 views
Today's project kind of jives with yesterday's in that it's an introduction kind of post, one that's simple and straight forward and yet does something that many people new to Kinect SDK development ask about...
a couple of days ago I asked how to paint a skeleton with the new KinectSDK in this post. Today’s post explains the basics in a few steps to paint the skeleton.
For this example we will use a form of WPF, which add a Canvas brush where the skeleton.
The following to keep in mind is to work with the sensor Kinect as a local variable of the form. In this post (link) talk a little in this regard.
Once controlled the State of the Kinect, the following is initialize the capture of skeleton (line 6 and 7) and subscribe to the event of change of frame for the skeleton (line 8).
In the implementation of this event, firstly we clean the canvas (line 14) and once validated the received frame (line 19) copy the array of skeletons to a local variable (line 21 and 22).
The concluding lines verify the State of the Joint of the head to see if tracking is correct and then use a helper of ElBruno.Kinect to paint the skeleton.
Project Information URL: http://elbruno.com/2012/03/20/kinectsdk-howto-paint-a-skeleton/