//Draws dots for the finger tips private void PaintFingerPoint(FingerPoint point, DrawingContext drawingContext) { drawingContext.DrawEllipse(Brushes.BlueViolet, null, new System.Windows.Point(point.X, point.Y), 5.5, 5.5); if (!CCT.NUI.Core.Point.IsZero(point.BaseLeft) && !CCT.NUI.Core.Point.IsZero(point.BaseRight)) { var baseCenter = CCT.NUI.Core.Point.Center(point.BaseLeft, point.BaseRight); drawingContext.DrawLine(this.orangePen, new System.Windows.Point(baseCenter.X, baseCenter.Y), new System.Windows.Point(point.X + point.DirectionVector.X * 60, point.Y + point.DirectionVector.Y * 60)); } }
private void Select(FingerPoint fingerTip) { ExecuteOnHitResult(fingerTip.Location, (hitTestResult) => { this.selectedVideo = GetByHitTest(hitTestResult as RayMeshGeometry3DHitTestResult); foreach (var video in this.videos.Where(v => v != selectedVideo)) { video.IsSelected = false; } this.selectedVideo.IsSelected = true; }); }
private void PaintFingerPoint(Graphics g, FingerPoint point) { g.FillEllipse(Brushes.Red, point.X - 5, point.Y - 5, 11, 11); // g.DrawString(point.Z.ToString(), this.font, Brushes.White, point.X + 3, point.Y + 3); //g.FillEllipse(Brushes.Orange, point.BaseLeft.X - 5, point.BaseLeft.Y - 5, 11, 11); //g.FillEllipse(Brushes.Orange, point.BaseRight.X - 5, point.BaseRight.Y - 5, 11, 11); if (!CCT.NUI.Core.Point.IsZero(point.BaseLeft) && !CCT.NUI.Core.Point.IsZero(point.BaseRight)) { var baseCenter = CCT.NUI.Core.Point.Center(point.BaseLeft, point.BaseRight); //g.DrawLine(Pens.Orange, baseCenter.X, baseCenter.Y, point.X + point.DirectionVector.X * 60, point.Y + point.DirectionVector.Y * 60); } }
private void PaintFingerPoint(FingerPoint point, DrawingContext drawingContext) { drawingContext.DrawEllipse(new SolidColorBrush(Color.FromArgb(Math.Min((byte)100, this.Opacity), 255, 255, 255)), null, new Point(point.X, point.Y), 10, 10); drawingContext.DrawEllipse(new SolidColorBrush(Color.FromArgb(this.Opacity, 255, 255, 255)), null, new Point(point.X, point.Y), 5.5, 5.5); }
private Point MapToPresentationArea(FingerPoint fingerPoint, Size originalSize) { var point = new Point(fingerPoint.X, fingerPoint.Y); return(new Point(point.X / originalSize.Width * this.TargetSize.Width, point.Y / originalSize.Height * this.TargetSize.Height)); }
public void ChooseGun(int gunid) { activegun = guns[gunid].GetComponent <FingerPoint>(); }