Example #1
0
 private void Update()
 {
     if (OVRInput.GetDown(OVRInput.Button.One))
     {
         rec.BeginRecording();
     }
     else if (OVRInput.GetUp(OVRInput.Button.One))
     {
         rec.EndRecording();
         rec.CheckRecognized();
     }
 }
Example #2
0
    IEnumerator GestureStarted()
    {
        rec.continuousGesturing = true;
        started = true;

        yield return(new WaitForSeconds(1.2f));

        bool hit = rec.ContinuousCheckRecognized();

        rec.continuousGesturing = false;
        rec.constantPositions.Clear();
        started = false;
        rec.EndRecording();
        positions.Clear();
        vels.Clear();
    }
    void Update()
    {
        if (Controller == null)
        {
            Debug.Log("Controller not initialized");
            return;
        }

        if (Controller.GetPressDown(triggerButton))
        {
            rec.BeginRecording();
        }
        if (Controller.GetPressUp(triggerButton))
        {
            rec.EndRecording();
        }
        if (Controller.GetPressDown(downPadButton))
        {
            rec.StoreGesture();
        }
    }