Jagan
Jagan

Reputation: 79

Kinect Grip Gesture for Click

I'm using kinect V2.0. I need to perform click using grip gesture. Is there a way to handle the Grip gesture in V2.0 like AddHandPointerGripHandler in V1.8.

Upvotes: 2

Views: 1120

Answers (1)

Vito Gentile
Vito Gentile

Reputation: 14426

In Microsoft Kinect SDK v2.0, the Body class includes two properties:

Both these properties are instances of the HandState enumeration, which specifies if the hand is:

  • Closed (and you can detect this to trigger the Grip gesture);
  • Lasso (which means that the hand is closed in a fist, except for a finger pointing upward)
  • Not Tracked (the hand state is not tracked)
  • Open (the hand is open)
  • Unknown

If you want to detect the Grip gesture, you can use a variable to save the last hand state detected, and then a "click" can be triggered every time this variable pass from an Open state to a Closed one.

Obviously, all of this can be executed every time you detect a SkeletonFrame.

Upvotes: 2

Related Questions