MCPcopy Create free account
hub / github.com/LibreVR/Revive / TrackedDevicePoseToOVRStatusFlags

Method TrackedDevicePoseToOVRStatusFlags

Revive/InputManager.cpp:209–224  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

207}
208
209unsigned int InputManager::TrackedDevicePoseToOVRStatusFlags(vr::TrackedDevicePose_t pose)
210{
211 unsigned int result = 0;
212
213 if (pose.bPoseIsValid)
214 {
215 result = ovrStatus_OrientationValid | ovrStatus_PositionValid;
216 if (pose.bDeviceIsConnected)
217 result |= ovrStatus_OrientationTracked;
218 if (pose.eTrackingResult != vr::TrackingResult_Calibrating_OutOfRange &&
219 pose.eTrackingResult != vr::TrackingResult_Running_OutOfRange)
220 result |= ovrStatus_PositionTracked;
221 }
222
223 return result;
224}
225
226ovrPoseStatef InputManager::TrackedDevicePoseToOVRPose(vr::TrackedDevicePose_t pose, ovrPoseStatef& lastPose, double time)
227{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected