Hand Position/Tracking in C++

It was my understanding that it is not possible to get the hand positions using the C++ API. I've seen solutions in Unity, but not in C++/UWP.

However, I just read on Microsoft's website that:
"For each hand that HoloLens detects, you can access its position (without orientation) and its pressed state. As the hand nears the edge of the gesture frame, you're also provided with a direction vector, which you can show to the user so they know how to move their hand to get it back where HoloLens can see it."

Has something changed?

Answers

  • Hi,

    What sort of 'tracking' are you looking for here? Is it what would be offered by the SpatialInteractionManager API?

    That API allows you to get called back as interaction sources (hands) are detected (finger pointing upwards I think) via the SourceDetected event and then as they move via the SourceUpdated event.

    When you get a SourceUpdated you can use the passed SpatialInteractionSourceEventArgs to dig in and try and get location if that's of interest to your app.

    Is this the type of thing that you had in mind? Those are the underlying UWP APIs so you should be able to use them from C++ nicely, I've just experimented with them from C# and they work for me there and I'd assume (can't be sure) that the Unity functionality you're thinking of would sit on top of these APIs.

    Hope that helps or provides some pointers.

Sign In or Register to comment.