I knew that kinect v2 camera can detect the skeleton joint position, but I need to know how can I determine the (x,y,z) position of a certain point in a room using kinect- v2 camera?
-
2What language are you use ? C#, C++, VB ? – Franckentien Jul 05 '16 at 00:11
3 Answers
For this you need to use CameraSpacePoint Structure
I give you an example in C#.
For that i will track the hand left and i suppose you have your joint.
internal Joint HandLeft;
For take a position you need to use this:
CameraSpacePoint pointLeft = HandLeft.Position;
After that you can use your position with this:
pointLeft.X
pointLeft.Y
pointLeft.Z
of course you can save the value in a float:
float test = pointLeft.Y;

- 324
- 6
- 21
-
In addition to this, if the point is outside the human body (i.e. within the depth frame, you just need to make a similar calculation) - please refer to MSDN pages for the proper documentation – 16per9 Jul 07 '16 at 16:20
you can determine the (x,y,z) position of 1-25 point of a person in kinect v2. (Z) means distance from each point to kinect sensor . if you need find each point of your frame you must use ColorFrame class then you can define your favorite position with Ellipse of course with a X-Y position. Your frame is 2D view frame so you dont have z position

- 1
- 1
- 5
you can take a look at Vitruvius libraries as it has the thing u are looking for like joint position and measuring distance.
This gets the y coordinate of the left hand joint
Example of joint code: body.Joints[JointType.HandLeft].Position.Y
This gets the distance of the coordinates to the Kinect V2 sensor
Example of distance code: Length(_bodies[_token.BodyArrIndex].Joints[JointType.SpineBase].Position)
Vitruvius GitHub link: https://github.com/LightBuzz/Vitruvius
Vitruvius GitHub Gesture joints link: https://github.com/LightBuzz/Vitruvius/tree/master/Kinect%20v2/WPF/LightBuzz.Vitruvius/Gestures
Vitruvius website: https://vitruviuskinect.com/
Hope it helps!

- 398
- 4
- 14