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

Method GetAnalog

ReviveXR/InputManager.cpp:306–315  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

304}
305
306float InputManager::Action::GetAnalog(XrSession session, ovrHandType hand) const
307{
308 XrActionStateGetInfo info = XR_TYPE(ACTION_STATE_GET_INFO);
309 info.action = m_Action;
310 info.subactionPath = m_IsHanded ? s_SubActionPaths[hand] : XR_NULL_PATH;
311 XrActionStateFloat data = XR_TYPE(ACTION_STATE_FLOAT);
312 XrResult rs = xrGetActionStateFloat(session, &info, &data);
313 assert(XR_SUCCEEDED(rs));
314 return data.currentState;
315}
316
317ovrVector2f InputManager::Action::GetVector(XrSession session, ovrHandType hand) const
318{

Callers 1

GetInputStateMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected