-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GetControllerState giving axis values of 0 #1183
Comments
Hi @Hokage3211 We do not currently support input (using SteamVR Input or the legacy API) going to applications whille the dashboard is visible. I don't know when or if that will change, but it would help to know more about your use case. Can you tell us what you're using the input for? Joe |
Essentially, and hoping this isn't going to be stolen as many people have told me this is a good idea, I'm wishing to make a better keyboard by using an Overlay for steamVR desktop/any game that could use the keyboard while in VR, one that uses the finger flexing with the new index controllers to allow people to type multiple keys with different fingers, like natural typing, because right now the steamVR dash keyboard is super slow and clunky, while mine could be used to type at decent words per minute. I have modified some of the steamVR code so that the overlay works as an actual constant overlay, since right now the plugin doesn't allow working overlays like OVRDrop without modification, but I couldn't have messed up anything like input processing, I don't believe. I used this "fix" which seems to have worked well for allowing the overlay to work without starting up steamVR and making it just a standalone useless application. ValveSoftware/steamvr_unity_plugin#336 Just to humor me, my method does not return the correct axis values even when the steamVR dashboard is closed, so how does steamVR get the finger curl values array populated properly? I've tried looking into the code but I couldn't figure out how to get a proper "handle" value for the getskeletonsummary on openVR, so I couldn't try to reproduce the code/behavior. |
I've heard lots of people suggest the same thing, so if somebody steals it, they probably didn't actually steal it. A few things:
I know none of that is good news... |
Well I'm not neccesarily looking to replace the keyboard directly, more just provide an overlay that pops up only when the desktop dashboard thing is open, so people can type fast while in VR finally. I only need to access the data coming directly from the openvr api/the controllers, which seems to be updated always as far as my tracking workaround has shown, yet getControllerState doesn't seem to work, I'm assuming you mean the function I'm using is not supported anymore? How does steamVR itself get the axis data from the controller, then? It has to, somehow, surely? |
I'm attempting to make a program with the openVR plugin for steamVR in Unity, and the program I want to make in the end requires that hand position/controller inputs are still monitored while the steamVR dashboard is visible, and sadly steamVR prefabs don't work, as whenever I open the steamVR dashboard the hands and headset stop tracking, so I've had to go deeper and use OpenVR functions myself to get this data, and the tracking does work, but I'm having trouble getting the controller state, specifically the finger flexes of the valve index/knuckles controllers.
OpenVR.System.GetControllerState(deviceIndex, ref state, (uint)System.Runtime.InteropServices.Marshal.SizeOf(state));
is my main code line for it, and when attempting to get the state.rAxis0.x or .y and the other axises, it only returns zeros, and I know that I am using the correct device index because I am getting the correct tracking data with the same index value.
Any advice? Or any tips if I'm barking up the wrong tree on how to track hands/controllers/fingers even while dashboard is open?
I would very much appreciate any help or ideas with a fresh set of eyes.
The text was updated successfully, but these errors were encountered: