Tutorials Unity

Unity VRTK & OVR Camera Rig for Android

Set up a scene in Unity using Virtual Reality Toolkit, or VRTK and the OVR camera rig prefab for use with Samsung’s Gear VR headset and a single controller OR for Oculus Go. This tutorial uses Unity 2017.4.0f1, VRTK v3.3.0, and Oculus Utilities 1.23.0

Assumptions: You already have Unity installed, you have a Gear VR headset with controller OR Oculus go and a compatible mobile device.

Are you looking to build for Oculus Quest? See this post instead: Vectorworks to Unity for Quest VR.


Import VRTK

Download VRTK 3.3.0 from Github, master branch as of 10.29.2018. Unzip the file and drag the entire VRTK folder into your assets window.


Import Oculus SDK

Download the following: Oculus Utilities 1.23.0 package (OVR)

Unzip the download. To import into Unity, go to main nav> Assets> Import Package> Custom Package. Only import the file named “OculusUtilities.unitypackage”.

Click “Import” on the following pop-up window. If there is a new version of OVR available, Unity will prompt you to install it, click Yes and allow Unity to restart.

Make sure to drop your OSIG into the project directory at Assets/Plugins/Android/assets.


Add VRTK SDK Manager

Delete the default main camera from your scene (right click> delete). Create an empty game object. Press enter/return while selected to rename it “VRTK SDK Manager”.

With your new “VRTK SDK Manager” object selected, add a component using the inspector window. Search for “VRTK_SDK Manager” and click to apply.


Add VRTK_SDK Setup

Create another empty game object in your scene & add the component “VRTK_SDK Setup” to the object. Make this object a child of “VRTK SDK Manager”. Set the SDK Selection dropdown to “Gear VR (Android: Oculus)”


Set up OVR Camera Rig

In your assets folder, click into OVR> Prefabs to find the “OVRCamearRig” object. Drag the prefab object into your scene as a child of the VRTK SDK Setup object.

Click on “OVRCameraRig” object. In the inspector window, find the “OVRManager (Script)” and set its Tracking Origin Type to Floor Level.

Open up the parent children objects of OVRCameraRig to find RightHandAnchor. Drag the OVR> Prefabs> Tracked Remote into your scene as a child of RightHandAnchor. Lastly, click into TrackedRemote to choose which 3d model remote you want to use. For example, if you are building for Gear VR, turn off the OculusGoControllerModel object by unchecking the box to the left of the object name in Inspector.

Then confirm your OVR Tracked remote script has Controller as ‘R Tracked Remote’ & the correct controller model object declared.


Confirm SDK Setup

Click on the VRTK SDK Manager parent object. In the inspector, drag the “TrackedRemote” object into the Right Controller field under Script Aliases.

Next, click on the Auto Populate button under setups to link your VRTK Setup object.


Switch to Android Platform

Switch to the  go to Main Nav> File> Build Settings. Select Android and then click “Switch Platform”. Close.

Now you have a basic VRTK setup for Gear VR! Keep in mind you will need to add pointer scripts to the GearVRControllerModel object depending on your project’s needs. Next, move onto this tutorial to set up your scene for teleport.


I hope this information will make it easier for you to get started working in VR. One of the goals of is to help designers learn and work faster, giving them more time to create and more easily share their ideas with the world!
Subscribe to my youtube channel for more VR tutorials.

You May Also be Interested In...