Open rhzxg opened 2 years ago
Just guessing, but maybe it's reliant on the tracker role, or if the buttons on it are used or bound.
@CodingDogzxg Did you find a solution to this? Does openvr have the capability to unassign a device as the main left or right controller (e.g. VIVE tracker with "held in hand" role), and then re-assign a new device (e.g. actual controller)?
We had a similar issue. @Rectus is probably right and the issue is caused by the tracker role.
Go to: SteamVR Settings > Controllers > Manage Trackers, and check if the tracker in question has the following tracker role assigned: "Held in Hand". If so, I think the tracker will be seen as a vr::ETrackedDeviceClass::TrackedDeviceClass_Controller
or vr::ETrackedControllerRole::TrackedControllerRole_LeftHand
/ vr::ETrackedControllerRole::TrackedControllerRole_RightHand
. If you don't want it to be a hand controller, you can just change its tracker role manually.
@pili-zhangqiu Thank you for your advice. Our CTO said it's not our responsibility to check whether the role OpenVR returns to us is right or wrong. We just use the tracker's role even though it's wrong. So that is kind of solving the whole problem, lol.
Sometimes OpenVR::GetTrackedDeviceClass identifies vive generic trackers (vr::TrackedDeviceClass_GenericTracker) as controllers (vr::TrackedDeviceClass_Controller) with almost no clue to debug.
It's very much random. This troubled me a lot, can you guys help me out? Thanks.