- Home /
How do you detect the Oculus remote without using OVRInput?
I'm working on adjusting an application that was built for the Vive to also be usable with Oculus, I've already got it working with the Touch controllers while still using SteamVR. Now I want to give the option of using the Oculus remote. To my understanding, Unity has native support for both the Touch controllers and the remote, but it doesn't seem to detect the remote. I set DPadX axis in the Input Manager to the correct joystick axis and called Input.GetAxis("DPadX") to no result. Using UnityEngine.Input.GetJoystickNames() only gives me the Touch controller. Every example I've found on Google is using OVRInput but I want to do it without OVR. I feel like I'm missing something obvious here. How do you detect the Oculus remote natively in Unity?
Thanks!
Update:
I tried importing the Oculus Utilites and added this script to an empty game object
void Update () {
OVRInput.Update(); // need to be called for checks below to work
if (OVRInput.Get(OVRInput.Button.DpadLeft))
{
print("left button pressed");
}
if (OVRInput.Get(OVRInput.Button.DpadRight))
{
print("right button pressed");
}
if (OVRInput.Get(OVRInput.Button.One))
{
print("round button pressed");
}
}
as suggested here http://answers.unity3d.com/questions/1171765/oculus-cv1-remote-input-mapping.html but I still get no response from the remote and it still doesn't show up in the GetJoystickNames()
Update again:
When Oculus is before OpenVR in the Virtual Reality SDKs in Player Settings, I can get button presses from the Oculus remote, but then all the OpenVR setup for the Touch controllers stops working. I want to have a single app for Oculus that will work with both the Touch and the remote, can I get it to use the remote and play nicely with OpenVR?