Hello, Leap Motion Team and Dev Community!
A very confused Leap Motion novice is in your need of help!
I'm currently studying computer science and my bachelor's thesis is drawing near. For said thesis I'd like to develop a prototype of an input device for camera based, perspective independent gesture recognition.
Instead of forcing the user to adjust themselves in accordance to a camera, I'd like to have it attached to the user's hand, so that it captures the fingers constantly from the same perspective. In combination with a device that measures the hand's position and orientation in relation the the user's body this should achieve a restricted, yet exploration worthy tool for gesture analysis.
I believe this prototype can be achieved by combining the technology of the Leap Motion controller with the trackers offered by the HTC Vive. That is why I'm currently developing an Unity Project that is meant to realise my idea, starting with the Leap Motion part.
What my scripts do so far, is, amont other things, to extract the data describing the finger bones. ( Link to Documentation)
The general idea is to acquire “local” joint rotations in form of (Leap)Quaternions, to simplify them by tracing them back to predefined rotation ranges and use that information as input for a finite state machine.
The important part is the “local” one. The Leap Motion is designed to register horizontal and vertical hand movement, as well as hand rotation. I, however, need to eliminate these factors because they are to be handled by the HTC Vive side of things and mustn't interfere with the analysis of the fingers. If a joint doesn't bend, then, even if the hand moves or rotates, the rotation value of the joint is not allowed to change.
Naturally I can't fixate the camera that well to my hand so that there is no “movement noise”. Shaking always does occur, so I figured the best way to get rid of it is to acquire a “local rotation” on the software side of things, which leads to my question(s):
Does the rotation attribute of a Bone object describe the rotation around the point centred in the Bone Joint closer to the wrist in local coordinates? (Or, alternatively, around another point inside the bone in local coordinates?)
So far, after translating a few Quaternions into Euler Angles, I sadly believe it doesn't... And if that is indeed the case: Is there an easy way to acquire the rotation values I need? Or should I work with something else?
Thank you very much in advance!! And sorry for the wall of text and asking something probably rather trivial... ^^°
Edit: Post shortened due to popular demand