Microsoft’s Kinect device has brought a whole new domain for developers to create innovative applications, which has amazed the end users with its great user experience. In this and couple of more blogs in coming weeks we will discuss the basics of Kinect programming that can get you started with Kinect application development using Kinect SDK.
Firstly, to start the development you will need a Kinect device and Kinect SDK installed on your system. You can download the latest Kinect SDK from here. In next few blogs we will be creating application in WPF that uses the Kinect device. Now before we start coding we need to know about the basic streams and frames of kinect device.They are:
- Skeleton Stream: Maintains the stream of skeleton data coming from the Kinect. The Kinect streams skeleton data using SkeletonFrame objects, each one of which contains one frame of skeleton data. The SkeletonStream contains data to track up to six skeletons at the same time.
- Depth Image Stream: Represents a stream of DepthImageStream objects.
- Color Stream: It represents a stream of ColorImageFrame objects.
Next we need to be aware of events related to the kinect device that we will deal with while developing kinect applications.They are:
- AllFramesReady: Event that fires when all frames are available.
- ColorFrameReady: Event that fires when a new color frame for the ColorStream is available.
- DepthFrameReady: Event that fires when a new depth frame for the DepthStream is available.
- SkeletonFrameReady: Event that fires when a new skeleton frame for the SkeletonStream is available.
Another important thing to look for is the KinectSensor Class. It represents a single kinect device.
Now the most basics thing that we need to do in all most all kinect applications are:
- Create a KinectSensor Class object.
- Identify attached kinect and assign it to the KinectSensor class object.
- Next enable different streams according to the applications requirement.
- Start kinect.
- Call the associated FrameReady event and do all the processing relevant to the application in these events.
- Once done stop kinect.
This should get any one started with kinect application development. In the next blog we will discuss further on kinect application development and will start with basic coding examples.