using Microsoft.Kinect; using MyGestureBank; using System; using System.Collections.Generic; using System.Linq; using System.Reflection; using System.Text; using System.Threading.Tasks; namespace PostureTester { public class Program { private static List> bones = new List>(); static void Main(string[] args) { // Create a body Body[] body = new Body[1]; // Create a posture PostureHandUpRight postureHandUpRight = new PostureHandUpRight(); PostureHandUpLeft postureHandUpLeft = new PostureHandUpLeft(); // Make the body do the posture bones.Add(new Tuple(JointType.Head, JointType.Neck)); bones.Add(new Tuple(JointType.Neck, JointType.SpineShoulder)); bones.Add(new Tuple(JointType.SpineShoulder, JointType.SpineMid)); bones.Add(new Tuple(JointType.SpineMid, JointType.SpineBase)); bones.Add(new Tuple(JointType.SpineShoulder, JointType.ShoulderRight)); bones.Add(new Tuple(JointType.SpineShoulder, JointType.ShoulderLeft)); bones.Add(new Tuple(JointType.SpineBase, JointType.HipRight)); bones.Add(new Tuple(JointType.SpineBase, JointType.HipLeft)); // Bras droit bones.Add(new Tuple(JointType.ShoulderRight, JointType.ElbowRight)); bones.Add(new Tuple(JointType.ElbowRight, JointType.WristRight)); bones.Add(new Tuple(JointType.WristRight, JointType.HandRight)); bones.Add(new Tuple(JointType.HandRight, JointType.HandTipRight)); bones.Add(new Tuple(JointType.WristRight, JointType.ThumbRight)); // Bras gauche bones.Add(new Tuple(JointType.ShoulderLeft, JointType.ElbowLeft)); bones.Add(new Tuple(JointType.ElbowLeft, JointType.WristLeft)); bones.Add(new Tuple(JointType.WristLeft, JointType.HandLeft)); bones.Add(new Tuple(JointType.HandLeft, JointType.HandTipLeft)); bones.Add(new Tuple(JointType.WristLeft, JointType.ThumbLeft)); // Jambe droite bones.Add(new Tuple(JointType.HipRight, JointType.KneeRight)); bones.Add(new Tuple(JointType.KneeRight, JointType.AnkleRight)); bones.Add(new Tuple(JointType.AnkleRight, JointType.FootRight)); // Jambe gauche bones.Add(new Tuple(JointType.HipLeft, JointType.KneeLeft)); bones.Add(new Tuple(JointType.KneeLeft, JointType.AnkleLeft)); bones.Add(new Tuple(JointType.AnkleLeft, JointType.FootLeft)); } } }