/// mono-behavior initialization
 protected override void InternalAwake()
 {
     base.InternalAwake();
     m_handPrimaryOverrideFilter = null;
     m_pointControlRaw           = null;
     m_pointControlSmooth        = null;
     m_pointControlSmoothFilter  = null;
     NINITECheckVersion.Instance.ValidatePrerequisite();
     m_curPointRaw          = new HandPointContext();
     m_curPoint             = new HandPointContext();
     m_curPointRaw.ID       = -1; // uninitialized
     m_curPoint.ID          = -1; // uninitialized
     m_lastFrameCurPoint    = null;
     m_lastFrameCurPointRaw = null;
 }
    /// callback when the point is updated
    /// @param sender the object that sent the event
    /// @param e the event arguments

    void myControl_PrimaryPointUpdateSmooth(object sender, HandEventArgs e)
    {
        m_lastFrameCurPoint.UpdatePoint(e.Hand.Position, e.Hand.Confidence);
        m_curPoint = e.Hand;
    }
Ejemplo n.º 3
0
 private System.Windows.Media.Media3D.Point3D?PointFromContext(HandPointContext context)
 {
     return(new System.Windows.Media.Media3D.Point3D(context.ptPosition.X, context.ptPosition.Y, context.ptPosition.Z));
 }
Ejemplo n.º 4
0
 private void PointControl_PrimaryPointCreate(ref HandPointContext context, ref Point3D ptfocus)
 {
     System.Windows.Media.Media3D.Point3D?point = PointFromContext(context);
     Dispatcher.BeginInvoke(() => { Point = point; });
 }
Ejemplo n.º 5
0
 void MyBox_PrimaryPointCreate(ref HandPointContext context, ref Point3D ptFocus)
 {
     flowRouter.SetActive(steadyDetector);
 }
Ejemplo n.º 6
0
 void MyBox_PrimaryPointCreate(ref HandPointContext context, ref Point3D ptFocus)
 {
     flowRouter.SetActive(steadyDetector);
 }
Ejemplo n.º 7
0
 private System.Windows.Media.Media3D.Point3D? PointFromContext(HandPointContext context)
 {
     return new System.Windows.Media.Media3D.Point3D(context.ptPosition.X, context.ptPosition.Y, context.ptPosition.Z);
 }
Ejemplo n.º 8
0
 private void PointControl_PrimaryPointUpdate(ref HandPointContext context)
 {
     System.Windows.Media.Media3D.Point3D? point = PointFromContext(context);
     Dispatcher.BeginInvoke(() => { Point = point; });
 }