using KinectUtils; using Microsoft.Kinect; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading; using System.Threading.Tasks; namespace MyGestureBank { /// /// The right hand down posture. /// public class PostureHandDownRight : Posture { public PostureHandDownRight() { GestureName = "HandDownRight"; } /// /// The test posture method. /// /// /// /// protected override bool TestPosture(Body body) { // Check if right hand is below the right hip var result = body.Joints[JointType.HandRight].Position.Y < body.Joints[JointType.HipRight].Position.Y && body.Joints[JointType.HandLeft].Position.Y > body.Joints[JointType.SpineBase].Position.Y && body.Joints[JointType.HandLeft].Position.Y < body.Joints[JointType.SpineShoulder].Position.Y; return result; } } }