Setting up Oculus Quest for Hand Tracking Development in Unity 2019.3 via Oculus Link
Updated: May 7, 2020
First, I updated to the latest stable version of Unity (2019.3.7f1), and brought in the latest version of the Oculus Integration Kit (v.15).
Which can be found here:
2. Connecting Oculus Quest via Link
Then I connected my Oculus Link cable to my Oculus Quest.
1.) Make sure to have the Hand Tracking Update installed and under Experimental Features enabled.
2.) Upon connecting your Oculus Link cable to your PC for the first time you will receive a pop-up, hit enable to allow Oculus Link to be activated.
3. Unity Project Settings
*Note that your Unity Platform has to be set to Android in order for this to work, additionally once your Quest is plugged-in you should see it appear under your Device List in Build Settings.
Under Unity Project Settings:
1.) Set your Color Space to Linear
2.) Minimum API Level to Android 4.4 "KitKat"
3.) Stereo Rendering Mode to Single-Pass
4. Oculus Platform Settings
Additionally, within Unity make sure the Oculus Platform Settings are set properly.
1.) This includes obtaining an Oculus Application ID from the Oculus Developer Dashboard.
(*Not having an application ID will prevent your Player Hands from rendering correctly)
To obtain an Oculus Application ID go to your Oculus Developer Dashboard and Select "Create New App". A new App ID will be generated for you.
Copy the generated App ID into your Oculus Platform Settings & OVRAvatar Settings in Unity.
2.) Make sure Virtual Reality is Supported under OculusPlatformSettings > Build Settings
5. Basic Grab Mechanics in Unity
Now lets setup some hand script components, grabbers, and grabbables in Unity. (As an example I hooked up some Chess pieces).
Now with the Oculus Integration setup in Unity drag OVRPlayerController.Prefab into a test scene.
Drag the OVRHandPrefab as a child of the LeftHandAnchor and RightHandAnchor within the OVRPlayerController.Prefab.
Make sure the Hand Type under the OVRHand(Script) is set to the corresponding hand (left/right).
Under OVRHandPrefab add a Rigidbody, Sphere Collider, and Hand Tracking Grabber(Script)
Make sure the OVRHandPrefab(Transform) is properly assigned under the Grip Transform Field.
Now, pick the object you would like to be able to grab. On that object add a Collider, Rigidbody, and OVR Grabbable(Script)
*Make sure to setup the Grab Points under OVR Grabbable(Script)
You should be set!
What makes this really cool is that you can now develop hand-tracking systems all within your Unity Sandbox, and test/preview with the press of a button! No need to build to device, Oculus Link works in conjunction with Oculus Quest to preview hand-tracking all in Unity.