Exemplo n.º 1
0
 void kinectService_SkeletonUpdated(object sender, SkeletonUpdatedEventArgs e)
 {
     if (this.kinectService.UserIsInRange)
     {
         this.OffsetX = e.HandRight.Position.X * Scale;
         this.OffsetY = e.HandRight.Position.Y * -Scale;
     }
 }
        void kinectService_SkeletonUpdated(object sender, SkeletonUpdatedEventArgs e)
        {
            UserPointColor = this.kinectService.UserIsInRange
                ? Color.FromArgb(255, 0, 255, 0) : Color.FromArgb(255, 255, 0, 0);

            TorsoOffsetX = (BoundsDisplaySize / 2) * e.Torso.Position.X / (BoundsWidth / 2);

            TorsoOffsetZ = (BoundsDisplaySize / 2) *
                (e.Torso.Position.Z - (MinDistanceFromCamera + BoundsDepth / 2))
                / (BoundsDepth / 2);
        }