Get Unity



November 6, 2019 update:

If you are familiar with.NET, follow our get-started step-by-step Unity tutorial to get you up and running as quick as possible. The explore the Unity's overview Documentation. If you're new to.NET, try Unity's self-guided tutorial. Unity also provides free courses for all experience levels on their Unity.

  • There's a new open source Cardboard SDK that offers a streamlined API, improved device compatibility, and built-in viewer profile QR code scanning. We recommend that all developers actively building for Google Cardboard migrate to the new Cardboard SDK: iOS, Android NDK, Unity XR Plugin (SDK)
October 15, 2019 update:
  1. Unity builds your project into an Android APK, installs it on the device, and launches it. Put the phone in your viewer and try out the demo. For more details on building Daydream apps in Unity, see: Daydream (3DoF) controller support in Unity; Resonance Audio; Daydream Elements; Streaming Video Support.
  2. Unity is available for download on Windows or Mac OSX. You must be on a laptop or desktop computer to download Unity.
  3. Unity is a cross-platform game engine developed by Unity Technologies, first announced and released in June 2005 at Apple Inc.' S Worldwide Developers Conference as a Mac OS X-exclusive game engine.As of 2018, the engine had been extended to support more than 25 platforms.The engine can be used to create three-dimensional, two-dimensional, virtual reality, and augmented reality games, as well.
  4. If it appears the Unity isn't launching or responding, wait a few more minutes before attempting to kill the process. If you are interested in the process NuGetForUnity follows or you are trying to debug an issue, you can force NuGetForUnity to use verbose logging to output an increased amount of data to the Unity.
  • The Daydream View VR headset is no longer available for purchase. However, you can continue to use the existing Google VR SDK to update and distribute your apps to the Google Play Store, and make them available to users in the Daydream app.

This guide shows you how to set up Google VR development with Unity and build ademo Daydream or Cardboard app for Android.

Set up your development environment

Hardware requirements:

  • Daydream: You'll need a Daydream-ready phoneand a Daydream View.

  • Cardboard: You'll need an Android device running Android 4.4 'KitKat'(API level 19) or higher and a Cardboard viewer.

Software requirements:

  • Install Unity:

    • Recommended version:LTS release 2018.4 or newer
    • Minimum version for 6DoF head tracking: 2017.3
    • Minimum version for smartphone: 5.6

    Make sure that the Android Build Support component is selectedduring installation.

  • Make sure your environment is configured for Android development.

    Refer to Unity's guide forAndroid SDK/NDK setup.

Download the Google VR SDK for Unity

Unity
  • Download the latest GoogleVRForUnity_*.unitypackage from thereleases page.

    The SDK includes the following demo scenes for Daydreamand Cardboard:

    SceneDescription
    HelloVRSimple VR game in which you find and select a geometric shape
    KeyboardDemoDaydream: Shows keyboard input on a UI canvas
    PermissionsDemoDaydream: Shows a correct user permissions request flow
    VideoDemoShows various ways to use stereo or 360° video through playback or remote streaming
    Hello6DoFControllers Demonstrates use of experimental 6DoF controllers

Get Unity

Import the Google VR Unity package

  1. Open Unity and create a new 3D project.

  2. Select Assets > Import Package > Custom Package.

  3. Select the GoogleVRForUnity_*.unitypackage file that you downloaded.

  4. In the Importing Package dialog, click Import.

    Accept any API upgrades,if prompted.

Unity

Configure settings

  1. Select File > Build Settings.

  2. Select Android and click Switch Platform.

  3. In the Build Settings window, click Player Settings.

    Configure the following player settings:

    SettingValue
    Player Settings >XR Settings >Virtual Reality SupportedEnabled
    Player Settings >XR Settings >Virtual Reality SDKsClick + and select Daydream or Cardboard
    Player Settings >Other Settings >Minimum API LevelDaydream:
    Android 7.0 'Nougat' (API level 24) or higher
    Cardboard:
    Android 4.4 'KitKat' (API level 19) or higher
    Player Settings >Other Settings >Package NameYour app's package identifier

Preview the demo scene in Unity

  1. In the Unity Project window, go to Google VR >Demos > Scenes. Open the HelloVR scene.

  2. Press the Play button. In the Game view you should see arendered demo scene.

    Note that although the scene here is monoscopic, the rendering on yourphone will be stereo. Unity might display this warning message as areminder:

    Virtual Reality SDK Daydream is not supported in Editor Play Mode.Please Build and run on a supported target device.Will attempt to enable None instead.

  3. Daydream: (Optional) You can use a physical Daydream controller insteadof simulated controls while in play mode in the editor. To do this, useInstant Preview.

  4. Interact with the scene using simulation controls:

    TypeSimulated actionWhat to do
    Head movementTurn your headHold Alt + move mouse
    Tilt your viewHold Control + move mouse
    Cardboard inputButton pressClick anywhere in the Game view
    Daydream inputChange controller orientationHold Shift + move mouse
    Click touchpad buttonHold Shift + click left
    Click app buttonHold Shift + click right
    Click home button to recenterHold Shift + click middle
    Touch the touchpad.
    To see the controller, tilt your view down
    Hold Control
    Change the touch position on the touchpad.
    To see the controller, tilt your view down
    Hold Control + move mouse

Prepare your device

To prepare your supported device, enable developer options and USB debugging.

Build and run the demo scene on your device

Get Unity Pro Free

  1. Connect your phone to your computer using a USB cable.

  2. Select File > Build and Run.

    Unity builds your project into an Android APK, installs it on the device,and launches it.

  3. Put the phone in your viewer and try out the demo.

Next steps

Unity 2017 Download Free

For more details on building Daydream apps in Unity, see: