| 146 | } |
| 147 | |
| 148 | XnStatus PoseToggleUserSelector::DetectOutOfPose(XnUserID nUserId) |
| 149 | { |
| 150 | XnUInt64 lastOutOfPoseTime; |
| 151 | |
| 152 | UserSelectionState* pState; |
| 153 | XnStatus nRetVal=m_hUsersState.Get(nUserId, pState); |
| 154 | if(nRetVal!=XN_STATUS_OK) |
| 155 | { |
| 156 | return nRetVal; |
| 157 | } |
| 158 | nRetVal=m_usersOutOfPoseTime.Get(nUserId,lastOutOfPoseTime); |
| 159 | if(nRetVal!=XN_STATUS_OK) |
| 160 | { |
| 161 | return nRetVal; |
| 162 | } |
| 163 | if(lastOutOfPoseTime!=0) |
| 164 | { |
| 165 | return XN_STATUS_OK; // we already have a number... |
| 166 | } |
| 167 | lastOutOfPoseTime=m_pUserGenerator->GetTimestamp(); |
| 168 | m_usersOutOfPoseTime.Set(nUserId,lastOutOfPoseTime); |
| 169 | return XN_STATUS_OK; |
| 170 | } |
| 171 | |
| 172 | void XN_CALLBACK_TYPE PoseToggleUserSelector::OutOfPoseCallback(xn::PoseDetectionCapability& /*capability*/, const XnChar* strPose, XnUserID nUserId,void* pCookie) |
| 173 | { |
no test coverage detected