using dp.kinect, how to make a mask from depthmap
Hi,
I want to create a mask from the kinect depthmap for showing my hand from image map.
I'm using "dp.kinect" library. I divide the depthmap into '0' and '1' using 'jit.op < ' for the mask.
But the result of mask appears 10 fingers not 5 fingers like 'mask.jpg'(attach). So, the result of video appears ' mask_video.jpg'(attach).
I want to show only 5 fingers without overlap in the mask.
Can anyone let me know how to solve this problem?
The patch is below.
Thanks!
As you might know the kinect projects a point cloud of IR dots and calculates the distance from the reflected IR light registered by its IR camera. The doubled hand is caused by the IR shadow of your hand. I think you can filter it out with a [jit.op > 0]. If that doesn't work try to check which depth value the shadow has and filter that out.
Alternatively, OpenNI has a function for returning only the pixels matching a user tracked in the depth image. That's effectively the best 'mask' you could get from the system. I don't know if this is implemented in the KinectSDK and dp.kinect.