Search Unity

  1. Unity 2019.1 is now released.
    Dismiss Notice

OVRInput Button not working on Oculus Go

Discussion in 'AR/VR (XR) Discussion' started by NotJelly, Dec 6, 2018.

  1. NotJelly


    Sep 21, 2018
    I am trying to register the input click from the Oculus Go touch pad controller. The code is halfway working, but somehow the click never registers.

    I have an OVR Manager in the scene, so OVRInput.Update() is definitely called.
    Then in my script, I have the following functions:

    Code (CSharp):
    1.     // Update is called once per frame
    2.     void Update ()
    3.     {
    4.         // THIS WORKS and prints non-zero output when I touch the touch pad
    5.         touchPosition = OVRInput.Get(OVRInput.Axis2D.PrimaryTouchpad);
    6.         Debug.Log("Touch position: " + touchPosition.ToString());
    8.         // THIS DOES NOT WORK and always prints 'No button down'
    9.        // no matter what button I press
    10.         if (OVRInput.GetDown(OVRInput.Button.PrimaryTouchpad))
    11.             Debug.Log("Some button down");
    12.         else
    13.             Debug.Log("No button down");
    15.     }
    What am I missing here? Why do my buttons not work?
    Last edited: Dec 6, 2018
    andywatts likes this.
  2. JoeStrout


    Jan 14, 2011
    I don't know; that should work if you actually click the thumb disc. It works for me. (Though I'm using Get rather than GetDown — but I would expect it to work either way.)

    Do other inputs (like OVRInput.Touch.PrimaryTouchpad or OVRInput.Button.PrimaryIndexTrigger) work for you?