单击的Kinect握笔手势 [英] Kinect Grip Gesture for Click
问题描述
我正在使用kinect V2.0.我需要使用握持手势执行点击.有没有办法像V1.8中的AddHandPointerGripHandler一样处理V2.0中的Grip手势.
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.
推荐答案
In Microsoft Kinect SDK v2.0, the Body
class includes two properties:
这两个属性都是HandState
枚举,它指定手是否为:
Both these properties are instances of the HandState
enumeration, which specifies if the hand is:
- 关闭(您可以检测到它来触发Grip手势);
- 套索(这意味着手被拳头合拢,除了手指指向上方)
- 未跟踪(手状态未跟踪)
- 张开(手张开)
- 未知
如果要检测握住手势,可以使用变量保存检测到的最后一只手的状态,然后每次该变量从从打开状态到关闭状态.
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.
显然,所有这些操作都可以在您每次检测到SkeletonFrame时执行.
Obviously, all of this can be executed every time you detect a SkeletonFrame.
这篇关于单击的Kinect握笔手势的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!