public void Kinect_SkeletonUpdated(object sender, SkeletonEventArgs e) { if (this.Kinect != null) { double x = this.Kinect.HandRight.X; double y = this.Kinect.HandRight.Y; if (IsInBounds(x, y, quitButton)) { if (quitButtonTimer == null) { StartTimer_Quit(1.5); } } else { StopTimer_Quit(); } if (IsInBounds(x, y, startButton)) { if (startButtonTimer == null) { StartTimer_Start(1.5); } } else { StopTimer_Start(); } } }
public void Kinect_SkeletonUpdated(object sender, SkeletonEventArgs e) { if (this.Kinect != null) { double x = this.Kinect.HandRight.X; double y = this.Kinect.HandRight.Y; if (IsInBounds(x, y, sliderMicLevel)) { this.MicLevelFraction = GetFraction(y, sliderMicLevel); } if (IsInBounds(x, y, sliderBpm)) { this.BpmFraction = GetFraction(y, sliderBpm); } if (IsInBounds(x, y, backButton)) { if (backButtonTimer == null) { StartTimer(1.5); } } else { StopTimer(); } } }
protected void RaiseSkeletonUpdate(SkeletonEventArgs e) { if (SkeletonUpdated != null) { SkeletonUpdated(this, e); } }