Unigine.Plugins.LeapMotion.Hand Struct
Hands are the main entity tracked by the Leap Motion controller. The controller maintains an inner model of the human hand and validates the data from its sensors against this model. This allows the controller to track finger positions even when a finger is not completely visible.
The Leap Motion software matches the internal model against the existing data. In some cases, the software can make an incorrect match – for example, identifying a right hand as a left hand.
This structure represents a physical hand detected by the Leap and provides access to its attributes describing the hand position, orientation, and movement. All coordinates are relative to the origin of the Leap Motion coordinate system.
The Hand structure is declared as follows:
public struct Hand
{
public int id;
public int type;
public int is_valid;
public float palm_width;
public vec3 palm_position;
public vec3 palm_stabilized_position;
public vec3 palm_velocity;
public vec3 palm_normal;
public vec3 direction;
public vec3 wrist_position;
public mat4 basis;
public Arm arm;
public Dictionary<int, Finger> fingers;
};
The last two items of the struct are:
arm | Arm of the hand. |
fingers | List of all fingers of the hand. |
LeapMotionHand Class
Properties
int id#
int type#
- 0 - left hand
- 1 - right hand