openvr
openvr copied to clipboard
Problem to override Oculus quest2 controller input.
Purpose: We want to control the movement by our own device, and are trying to make our device compatible with all kinds of VR headsets. Things goes well on HTC Vive, but problems occur when working with Oculus Quest2.
Steps:
- Create StreamVR Custom Driver.
- Set the loadPriority to -100. loadPriority of Oculus device is 0 by default, so Oculus device should be loaded early than custom driver.
- Get Oculus quest2 device in Custom Driver, and add an input component(CreateScalarComponent) to Input Device(/input/joystick/x).
- Call UpdateScalarComponent in RunFrame function of IServerTrackedDeviceProvider , in order to update Oculus quest2 controller input(/input/joystick/x).
Expectation: It's expected that we can now override Oculus controller input in my custom driver.
Problem: We do override the input of Oculus quest2 Controller, however, the input result will be overrided back by Oculus quest2 controller periodically。 but this problem keeps stopping our movement periodically. Is this because Oculus starts there's own OpenVR Driver in another process?
Any Ideas? Thanks!