@Override
    public boolean isButtonDown(int controllerIndex, VRInputType checkButton) {
        VRControllerState_t cs = cStates[OpenVRInput.controllerIndex[controllerIndex]];
        switch( checkButton ) {
            default:
                return false;
            case ViveGripButton:
                return (cs.ulButtonPressed & 4) != 0;
            case ViveMenuButton:
                return (cs.ulButtonPressed & 2) != 0;
            case ViveTrackpadAxis:
                return (cs.ulButtonPressed & 4294967296l) != 0;
            case ViveTriggerAxis:
                return (cs.ulButtonPressed & 8589934592l) != 0;
        }
    }
Create a new <a href="https://github.com/ValveSoftware/openvr/wiki/API-Documentation">OpenVR</a> input attached to the given VR environment.
@param environment the VR environment to which the input is attached.
jme3-vr/src/main/java/com/jme3/input/vr/openvr/OpenVRInput.java