When I start a new VR project in Unity 5 I always map the Recenter function to both the ‘R’ key and the XBox Controller Right Joystick button (which is the stick for rotating the user). It does not need the Oculus Utilities SDK.

It’s quick and easy.

1. Add a new Input item for pressing a key or joystick button named “Recenter”

Edit -> Project Settings -> Input, and insert a new item and name it “Recenter”:

Set the following:

Positive Button: “r”
Alt Positive Button: “joystick button 9″
Type: Key or mouse button

XBox Controller Input Mapping

2. Add a script to detect “Recenter” being pressed and call the VR Tracker Recenter function.

Here’s the code:

VRRecenter.cs:

// Recenter input mapping for VR by Peter Koch <peterept@gmail.com>
using UnityEngine;
using UnityEngine.VR;
using System.Collections;

// To use:
// 1. Drag this script onto any game object
// 2. Map "Recenter" in the input manager to use XBox Right Joystick Button and 'r' key: 
//    Ref: http://blogs.msdn.com/b/nathalievangelist/archive/2014/12/16/joystick-input-in-unity-using-xbox360-controller.aspx
//    Edit -> Project Settings -> Input, and insert a new item and name it "Recenter":
//     Positive Button: "r"
//     Alt Positive Button: "joystick button 9"
//     Type: Key or mouse button 
public class VRRecenter : MonoBehaviour 
{
   void Update () 
   {
      if (Input.GetButtonDown("Recenter"))
      {
         Debug.Log("VR Recenter");
         InputTracking.Recenter();
      }
   }
}