I’m nearly done with my OpenXR implementation, in less than 1000 lines of code. I have boolean, value, and pose inputs working, but have hit a problem with vector2f inputs. I am using an Oculus touch controller.
In the XrInteractionProfileSuggestedBinding structure, interactionProfile is set to “/interaction_profiles/oculus/touch_controller” and the suggestedBindings member contains these two values:
- “/user/hand/right/input/thumbstick/x”
- “/user/hand/right/input/thumbstick/y”
I am not declaring any subaction values.
I expect the program to fill in the values for the XrActionStateVector2f value when xrGetActionStateVector2f is called, but the value is always (0.0, 0.0). I am checking the return values of all OpenXR commands and they are always XR_SUCCESS. All other types of inputs are working as expected.
I also tried setting suggestedBindings to a single value “/user/hand/right/input/thumbstick”, with the same result.
Do I misunderstand how vector2f inputs are supposed to work in OpenXR? The tutorial I am following leaves this topic out: