0
votes

I have been researching and trying a lot of techniques to solve the problem. I have obtained hand's coordinates from Skeleton data. Using these coordinates I want to crop the region out of depth data and display it as the hand location changes. I have already converted the rgb and depth stream to bitmap. I am working on windows form as I am running short on time. How can I map Skeleton coordinates on Depth data coordinates? and Also how to simply filter out every depth frame pixel which is farther than a specific value? I know Kinect provides depth map but a little heads up on how to access it and make it work with windows form would be appreciated.

1

1 Answers

1
votes

You need to use Coordinatemapper class to map a skeleton joint to 2D coordinates. The SDK has defined two classes for both color images and depth images: ColorSpacePoint and DepthSpacePoint. Both structures contain the value of x and y in pixels, that is what you want. To do the conversion, you can try the code in this way:

ColorSpacePoint colorspacepoint=m_pCoordinatemapper->MapCameraPointToColorSpace(point);

To access the frame data, you can try AccessUnderlyingBuffer() method of IDepthFrame interface.

Hope this helps.