I've been reading through the Oculus for Mobile development basics. There are tons of links everywhere, and it's unclear which steps are needed for GearGR and which ones are needed for Oculus Go, and it's just a mess and nothing's working. Is there a simple guide for how to just get everything going?
Asked
Active
Viewed 850 times
1 Answers
4
Install prerequisites
- Install Unity
- Install Android Studio
- If you're running Windows, you'll have to install the ADB drivers. On a Mac, you're good to go and can ignore this step.
- Launch Android Studio, click Configure in the bottom right corner, and click SDK Manager.
- Under SDK Platforms, check every platform from API level 21 and above. Don't press Apply/Ok yet.
- Under SDK Tools, enable Android SDK Build-Tools, LLDB, Android SDK Platform-Tools, Android SDK Tools, HAXM, NDK
- Press Ok or Apply. A ton of stuff will be downloaded and installed. Afterwards the "Ok" button will be broken, so force-quit Android Studio.
- If you're running Windows you have to set up a bunch of environment variables. On a Mac, you're good to go and can ignore this step.
- Note that for the Oculus Go (as opposed to the GearVR), you do NOT need an OSIG file for any purpose, development nor deployment. Just ignore every reference to it.
Enable developer mode
- Open the Oculus app on your phone.
- Settings > Tap your Oculus Go > Wait for it to connect... > More Settings > Developer Mode > Enable
- It'll prompt you to create a developer organization in your dev dashboard. Tap the link and follow the instructions in the browser. You'll be creating an app and an "app id". Save this app ID for later. (see screenshot below)
- Once you're done becoming an oculus developer and creating an app id, try to enable developer mode from your phone again; now it'll succeed.
- Connect your Oculus Go to your computer with a USB cable.
- In your terminal/shell, type
adb shell getprop
. It'll find your Oculus but it's unauthorized. - Without unplugging your Oculus, put it on your head and using the controller, tap the allow button in the Android permissions dialog.
- Take off the headset, and try the
adb shell getprop
command again.
Integrate Oculus into your Unity project
- Create a new Unity project, or open an existing one.
- From the Asset store, download "Oculus Integration", and import it into your project. You can select everything and just import it.
- In your Project pane, under Oculus > VR > Prefabs, find OVRCameraRig. Pull it into your scene hierarchy.
- Disable or remove your existing Main Camera.
- Go to Edit > Project Settings > Player. Go to the "Android" tab.
- Under "Other Settings", set Package Name to "com.{your_domain}.{your_app_name}", replacing the bracketed names with appropriate names
- Change Minimum API Level to 21.
- Under "XR Settings", under "Virtual Reality SDKs", tap + and add Oculus.
- From your menu bar, select Oculus Platform > Edit Settings. A new inspector appears. For "Gear VR App id", fill in the "app id" from step 12. Make sure "Build Settings" has virtual reality support checked, and the bundle identifier is the same as in step 23.
Build and run
- Open the menu File > Build Settings. Choose Android.
- Set Build System to "Internal".
- Select your device under "Run Device". It should be called "Oculus Pacific" or something.
- Press Build And Run. Hooray, now you're running your VR game on your Oculus Go!

nevyn
- 7,052
- 3
- 32
- 43
-
this is helpful for setting build/graphic settings: https://developer.oculus.com/blog/tech-note-unity-settings-for-mobile-vr/ – pale bone Oct 19 '18 at 17:20
-
@palebone wow, that's really comprehensive! Thanks! :) (maybe they should have a template project with all of that set up though :S) – nevyn Oct 19 '18 at 18:50
-
Agreed, there are some shortcuts that address some issues covered in the blog in the tools>Oculus>performance lint tool – pale bone Oct 20 '18 at 06:03