// ポーズ検出
        void poseDetect_PoseDetected(object sender, PoseDetectedEventArgs e)
        {
            message = "ポーズ検出:" + e.Pose + " ユーザー:" + e.ID;

              // ポーズの検出を停止し、キャリブレーションを開始する
              user.PoseDetectionCapability.StopPoseDetection(e.ID);
              user.SkeletonCapability.RequestCalibration(e.ID, true);
        }
 void poseDetectionCapability_PoseDetected(object sender, PoseDetectedEventArgs e)
 {
     this.poseDetectionCapability.StopPoseDetection(e.ID);
     this.skeletonCapbility.RequestCalibration(e.ID, true);
 }
 void _pose_detect_caps_PoseDetected(object sender, PoseDetectedEventArgs e)
 {
     _pose_detect_caps.StopPoseDetection(e.ID);
     _skeleton_caps.RequestCalibration(e.ID, true);
     Console.WriteLine("Detected pose of user " + e.ID + " start calibrating");
 }
    /// @brief pose detection callback
    /// 
    /// @param sender who called the callback
    /// @param e the arguments of the event.
    private void PoseDetectedCallback(object sender, PoseDetectedEventArgs e)
    {
        m_contextManager.Log("found pose " + e.Pose + " for user=" + e.ID, NIEventLogger.Categories.Callbacks, NIEventLogger.Sources.Skeleton, NIEventLogger.VerboseLevel.Verbose);

        if (e.Pose.CompareTo(m_PoseToSelect)!=0 && e.Pose.CompareTo(m_PoseToUnselect)!=0)
            return; // irrelevant pose

        NIPlayerPoseCandidateObject poseUser = GetUserFromUserID(e.ID) as NIPlayerPoseCandidateObject;
        if (poseUser == null)
            return; // irrelevant user
        if(e.Pose.CompareTo(m_PoseToSelect)==0)
        {
            DetectSelectionPoseForUser(poseUser);
        }
        if (e.Pose.CompareTo(m_PoseToUnselect)==0) // we do NOT put an else because the select and unselect might be the same pose
        {
            DetectUnselectionPoseForUser(poseUser);
        }
    }
示例#5
0
        void poseDetectionCapability_PoseDetected(object sender, PoseDetectedEventArgs e)
        {
            int id = e.ID;
            if (isFirstPoseAttempted || this.skeletonCapability.IsCalibrating(id))
                return;
            isFirstPoseAttempted = true;

            this.poseDetectionCapability.StopPoseDetection(id);
            this.skeletonCapability.RequestCalibration(id, true);
            OnPoseRecognized((int)id);
        }
    void poseDetectionCapability_PoseDetected(object sender, PoseDetectedEventArgs e)
    {
        this.poseDetectionCapability.StopPoseDetection(e.ID);
		SendMessage("PoseDetected", e, SendMessageOptions.DontRequireReceiver);
        if (AttemptToCalibrate)
        {
            this.skeletonCapbility.RequestCalibration(e.ID, true);
			calibratingUsers.Add(e.ID);
        }
    }
        void PoseDetectionCapability_PoseDetected(object sender, PoseDetectedEventArgs e)
        {
            KinectUser user = _FindUser(e.ID);

            if (user != null)
            {
                PoseDetected.Raise(this, user, e.Pose);
            }

            if (_SkeletonCapability.IsCalibrating(e.ID))
            {
                return;
            }

            _PoseDetectionCapability.StopPoseDetection(e.ID);
            _SkeletonCapability.RequestCalibration(e.ID, true);

            CalibrationStarted.Raise(this, user);
        }
 void poseDetectionCapability_PoseDetected(object sender, PoseDetectedEventArgs e)
 {
     this.poseDetectionCapability.StopPoseDetection(e.ID);
     if (AttemptToCalibrate)
     {
         this.skeletonCapbility.RequestCalibration(e.ID, true);
         calibratingUsers.Add(e.ID);
     }
 }
示例#9
0
 void HandlePoseDetectionCapabilityPoseDetected(object sender, PoseDetectedEventArgs pd)
 {
     HUD.text = (HUD.text + "\nPose Detected: " + pd.Pose);
     poseDetectionCapability.StopPoseDetection (pd.ID);
     skeletonCapability.RequestCalibration (pd.ID, true);
 }
 private void PoseDetected(object sender, PoseDetectedEventArgs e)
 {
     Console.Write(e.ID + " Detected pose " + e.Pose);
     userGenerator.PoseDetectionCapability.StopPoseDetection(e.ID);
     userGenerator.SkeletonCapability.RequestCalibration(e.ID, true);
 }