UE5 Cardboard VR 1.5.0
Unreal Engine plugin to run UE4 and UE5 mobile VR projects on iOS and Android devices using Google Cardboard VR viewers.
Loading...
Searching...
No Matches
Cardboard VR plugin for Unreal Engine 5

Introduction

UE5 Cardboard VR is a plugin for Unreal Engine 5 that adds support for Google Cardboard VR headsets for both iOS and Android platforms, integrating the official Google Cardboard SDK.

FAB MARKETPLACE: https://www.fab.com/listings/f227f0ad-72b7-4a0f-beb2-e955cca363c0

To configure and use the plugin, read Quick Start. There's a Sample Project available at https://github.com/UNAmedia/ue5-cardboard-demo.

NOTE: This product is not made by, or affiliated with, Google Inc in any way. "Google Cardboard" is a trademark of Google LLC.

Integrated Google Cardboard SDK versions:

Links

FAB MARKETPLACE: https://www.fab.com/listings/f227f0ad-72b7-4a0f-beb2-e955cca363c0

Changelog: Changelog

Discord server: https://discord.gg/PuAyhDctHp

Join us on Discord

Knowledge Base: https://www.unamedia.com/help/ue5-cardboard/start

Support forum: https://forums.unrealengine.com/unreal-engine/marketplace/1849407-cardboard-vr-google-cardboard-vr-headsets-on-ios-and-android-integrating-the-official-google-sdk

Sample project: https://github.com/UNAmedia/ue5-cardboard-demo

Main Features

The plugin allows you to run UE4 and UE5 mobile VR projects for iOS and Android devices on the Google Cardboard VR viewers.

Main supported features:

  • head tracking;
  • stereoscopic rendering;
  • user interaction via the viewer button;
  • native, customizable, UI overlay to allow the user to:
    • enable/disable the stereoscopic mode;
    • scan the QR code to automatically configure the parameters of its Google Cardboard viewer.
  • all the features are available from both Blueprints and C++.

User interactions via the viewer button are detected as standard touch inputs.

User interactions with the UI overlay are notified by delegates, while the UI overlay can be customized from the Project Settings and also at run-time.

Quick Start

Simply enabling the plugin (under the Edit > Plugins menu and searching for "Cardboard VR") is enough to start building and running your mobile VR experience on a Google Cardboard-supported mobile device.

For a proper and complete setup, more advanced options and important technical notes, please read the rest of the document.

Project Setup

Ensure to have enabled the plugin (under the Edit > Plugins menu and searching for "Cardboard VR").

Project Settings

  • Google Cardboard viewers expect the smartphones to be handled in a fixed orientation:
    • for iOS: go to Project Settings > Platforms > iOS:
      • unset all Supports ... Orientation options, leaving enabled only the Supports Landscape Right Orientation;
      • set Preferred Landscape Orientation option to Landscape (right home button) value.
        iOS orientation settings
    • for Android: go to Project Settings > Platforms > Android and set the option APK Packaging > Orientation to the value Landscape.
      Android orientation settings
  • If using Unreal Engine 4.25 or earlier:

Optionally, you could be interested to configure few other options under Project Settings:

  • Project > Description > Settings > Start in VR: if enabled, your app will start in stereo mode;
  • under Engine > Input :
    • Mobile > Default Touch Interface: if set, your app will show the configured touch interface when not in stereo mode (when in stereo mode, the touch interface is automatically removed by the plugin);
    • Mouse Properties > Use Mouse for Touch: helpful when testing your experience on PC.
  • for iOS, under Platforms > iOS > Power Usage, set Frame Rate Lock to None and activate Enable Dynamic Max FPS.

Please follow all the other recommendations by Epic for developing for VR and mobile (like disabling the Mobile HDR option, configuring the Mobile Content Scale Factor, enabling and customizing frame pacing, etc.). See the section Useful Development Links for more detailed information.

Plugin Settings

Under Project Settings > ... > Cardboard VR, you can customize several settings of the plugin. Go over each setting with the mouse pointer to open a tooltip with the detailed description. Most of the settings can be updated at run-time using methods from the UUNACardboardVRStatics class.

Plugin settings

Set Up Camera for UE5 Cardboard VR

You must setup your VR camera following the official guidelines of Unreal Engine for a seated VR experience:

  • attach a camera component to a scene component at the base of the pawn/character (ground level);
    UE5 Cardboard VR camera setup
  • on initialization at run-time, set the Tracking Origin to Eye Level and move upward the camera's parent scene node to the desired Eye Height.
    UE5 Cardboard VR camera initialization

Follow the links below, from the official Unreal Engine Documentation, for more information:

Note that you can use the UE5 Cardboard VR plugin to access the head tracking data also when not in VR mode. You can read more about it in Access the HMD orientation when not in VR-mode.

Technical Notes

  • Tablets (in particular iPad tablets) are not supported by the Google Cardboard SDK at the moment (see the official repository). While the stereo mode can be safely enabled with the plugin (that will work as on smartphones), the Google Cardboard viewer parameters and the distorsion mesh could not correctly match the physical size of the device screen. If you prefer to not support the stereo mode on tablets, you can manually detect the device type on launch and selectively enable/disable the native UI overlay.
  • In UE5.0-5.4, the Android Vulkan rendering system of Unreal Engine has a bug and crashes when the QR code scan activity is used. This is caused by the Frame Pacing implementation and disabling it prevents the crash:
    [ConsoleVariables]
    a.UseSwappyForFramePacing=0
  • On UE4.25, setting r.MobileHDR to false is not supported (there's a bug in the engine rendering pipeline causing an unexpected distortion on the left eye).

Useful Development Links

Google Cardboard apps are both VR apps and mobile apps, please review and follow all the relevant Unreal Engine documents and recommendations about the subjects, for example:

As the plugin integrates the official Google Cardboard SDK, you can find important and helpful information also from Google: