This guide covers everything you need to know to get started developing Unreal applications for the Oculus Quest.
This topic contains the following sections:
There are a number of ways that you can obtain the Oculus Unreal distributions.
You can obtain a binary distribution with the Epic Game Launcher. This Oculus code may be two or more versions behind the latest Oculus SDK, but if you are a beginning developer, choose this binary distribution. It is stable, and does not require downloading the source from GitHub, setting up Visual Studio, and compiling the entire Unreal game engine source code, which is a lengthy process. The following image shows an example:
You can also get source distributions from GitHub if you have the correct access.
To access the Epic and Oculus GitHub repositories, you must be logged in to GitHub and subscribed to the private EpicGames/UnrealEngine repository. See UE4 on GitHub for details. Otherwise, you will receive a 404 error when you try to access the repository links. An Unreal license is not required.
You can obtain the most up-to-date source distribution from the Oculus GitHub Repository. These distributions are the most up-to-date with the latest Oculus SDKs. We support the current release of UE4 and any preview of the next release of UE4. Please see the Oculus GitHub Repository table in Version Compatibility Reference, in order to choose the specific downloads that best suit your development criteria. While new Oculus features ship first to the Oculus GitHub versions, API changes may occur when these branches are merged back into Epic’s version of the engine. We recommend these distributions for professional developers who would like to access the latest Oculus SDK features. In order to build this source base, see Building UE4 from Source.
You can obtain a source distribution from the Epic GitHub Repository. This Oculus code may be several versions behind the latest Oculus integrations. Please see the Epic GitHub Repository table in Version Compatibility Reference, in order to choose the specific downloads that best suit your development criteria.
These steps describe Unreal Engine 4.25. The screens and instructions may vary for different versions of Unreal Engine.
Download and setup the version Unreal Engine that you wish to use. Check the Version Compatibility Reference for the list of SDKs that ship with each version.
Set up Unreal 4.25 for Android Development by installing Android Studio. Unreal requires the Android SDK and NDK, Ant scripting and JDK, as well as specific environment variables, which are included with Android Studio. Note that earlier versions of Unreal required NVidia CodeWorks.
Find instructions for installing Android Studio and uninstalling CodeWorks in Unreal’s documentation: Setting up Android SDK and NDK for Unreal.
For older versions, of Unreal, you can find the installer for CodeWorks at the following location: https://docs.unrealengine.com/en-US/Platforms/Mobile/Android/Setup/AndroidStudio/index.html
For example, on Windows 10, you would likely find the installer,
C:\Program Files\Epic Games\UE_4.24\Engine\Extras\AndroidWorks\Win64\. On macOS Catalina, you would likely find the installer,
In this section you will use Unreal Engine to create a project for Oculus development.
At the bottom of the screen:
Your screen should look like this:
In this section, you will enable the Oculus plug in and modify some project settings to work with Oculus devices.
Select Edit > Plugins, choose the Virtual Reality section, and make sure that the OculusVR Plugin is enabled.
Select Edit > Project Settings. Then, under Project, select the Maps & Modes section:
Under Default Maps, set both the Editor Startup Map and the Game Default Map to the Level that you just saved:
Scroll down and select Engine > Input. Locate the Mobile section:
For Default Touch Interface, select Clear, which sets this value to None:
The result should look like this:
Scroll down to the Platforms section, select Android. Then scroll down on the right-hand side to the APK Packaging section, and if necessary click Configure Now:
Set the following settings depending on your target device.
For Quest/Quest 2:
The following image shows an example of the settings for Quest.
Open Advanced APKPackaging and click the + next to Package for Oculus Mobile Devices. From the drop-down select Oculus Quest and Oculus Quest 2.
Click on the Android SDK section, and make sure that Android SDK tools that are needed to build your project point to the correct folder on your computer, and you have set the API levels per your device. See Setup Unreal Engine for Android Development for more info.
Scroll to the Engine section, select Rendering, and under Mobile and then Mobile MSAA, make sure 4x MSAA is selected.
Scroll further to the VR section of the Rendering settings and make sure Mobile HDR is turned off. The following image shows an example.
Note that you may need to restart your project for some of these settings to be applied.
Note that many of the settings described in this topic are also provided in the Oculus Performance Window. For more information, see Oculus Performance Settings.
This section describes how to launch your UE4 project so that it can be viewed in the Oculus Quest headset.
In the UE4 Editor, click beside the Launch icon to open Options for Launching on a Device:
All Unreal apps that ship on the Oculus Store are recommended to implement the Entitlement Check to verify that the user’s app is legitimate. For information about how to implement the Entitlement Check, please see the Unreal Development Getting Started in the Platform Solutions guide.
Configure different aspects of your Oculus app such as whether it supports hand tracking, what level of FFR it uses, and set the color space using the Plugin Settings. For more information, see Plugin Settings.
When you are ready to distribute your application, an Android Distribution Keystore is required for submission to the Oculus Store.
Before building your final release package, create a new Android keystore as described in the section “Manually Sign an APK” in Android’s Sign your Applications guide. Once you have generated your distribution keystore, in the Unreal Editor, go to Edit > Project Settings > Platforms > Android, scroll down to Distribution Signing, and enter the required information.
See the Application Signing section of the Mobile SDK documentation for more information.
Note: It is important to review Distribute, which covers Oculus Store submission requirements and guidelines.