Daydream VR Cookbook Downloads

Here you will find code downloads, errata and additional compilmentary chapter material.

The following Unity packages were built against Daydream GVR SDK for Unity v1.170.0, ARCore SDK for Unity v1.3.0, and Unity 2018.2.0f2.

Need some AR inspiration? Check out Experiments With Google.

Since writing this book there have been several new additions to the ARCore SDK. In the coming months I will create recipes for each of them, but in the mean time refer to the ARCore developer site for more info on each of these features:

ARCore for iOS

ARCore Instant Preview when building in the Unity Editor

Augmented Images that lets your AR app respond and track 2D images.

Cloud Anchors to allow for multiplayer, persistent or collaborative AR experiences.

ARCore Development Troubleshooting

Working out why your ARCore app isn't running as expected can be endlessly frustrating. To get things working properly follow the steps in chapter 7 of the book on setting up your dev environment for ARCore. Here area some things to double check if you run into problems setting up your ARCore enviroment and building to the phone.

To install the Unity packages from the links below, after downloading from GitHub create a separate Unity project for each of the chapters. When the project is open, manually drag and drop the chapter package into the assets folder of the currently open Unity Project, this will install it. In Build Settings make sure to switch the Build Platform to Android (File > Build Settings). Make sure your Android phone is running at least Android 7.0 and has the latest version of ARCore installed on it from the Google Play Store, if not update it. In the Player Settings, under Other Settings, make sure to update the Package Name to look something like: com.daydreambook.chapter7. Make sure the Minimum API level is Android 7.0 or higher and the target is auto/highest. Under XR Settings make sure to select ARCore Supported.

Make sure you have actually added the current scene you are building to the Scenes to Build list in Build Settings. By default a new Unity project adds the empty demo scene, delete this by selecting it and hitting delete, and either leave it blank to automatically add the currently open scene, or manually add a scene to the list.

If a dialog appears that says "Missing Project ID", or something similar, just press continue.

If you are still have problems try deleting any previous apk version of the Unity project that may be on your phone.

IMPORTANT UPDATE for Unity 2019 - April 2019

There have been some changes to Unity 2019 that differ from the book, this will affect how you setup your Unity ARCore project.

On installation of Unity 2019 make sure to select Android Bulid Support. This will automatically install the Android SDK and the Java JDK. You no longer need to manually download these and link them in the Unity Preferences window. This update greatly simplifies the process of setting up your Android development environment in Unity, read more about it in the Unity docs

In Unity 2019 only, for ARCore development (Chapters 7,8, and 9) you will need to install some packages into your project using the package manager. Select Window > Package Manager. Then select and install the following packages: Multiplayer HLAPI (required by the CloudAnchors sample) and XR Legacy Input Helpers (Instant Preview requires the TrackedPoseDriver). Now you can import the chapter's sample file package without errors or warnings. For more info see the ARCore Unity quickstart guide: https://developers.google.com/ar/develop/unity/quickstart-android

I also had to remove "Vulcan" from Player Settings after selecting XR Settings > ARCore Supported. Do this in Player Settings / Other Settings / Graphics APIs and click the minus sign next to Vulcan to remove it. Vulcan does not currently support ARCore. If you don't see Vulcan then you can skip this.

When you build and run on device it might say you need to update Android API level to 26 or something similar. Follow the prompts to do this.

Remember you will need to build these scenes to a ARCore supported Android device, they will throw errors if you run them in the Unity Editor.

Chapter 1

There are no companion files for chapter 1.

Here is a link to Ivan Sutherland's Sword of Damocles and original head mounted display, and here's a great YouTube video. Here is Morton Heilig's Sensorama.

Chapter 2

Download the companion Unity package from GitHub.

Chapter 3

Download the companion Unity package from GitHub.

Chapter 4

Download the companion Unity package from GitHub.

Download the Daydream VR Sketch sticker sheet here.

Chapter 5

Download the companion Unity package from GitHub.

Chapter 6

Download the companion Unity package from GitHub.

Chapter 7

Download the companion Unity package from GitHub. Built with ARCore 1.8. (Updated April 27, 2019). See GitHub release notes for more info.

Chapter 8

Download the companion Unity package from GitHub. Built with ARCore 1.8. (Updated April 27, 2019). See GitHub release notes for more info.

Chapter 9

Download the companion Unity package from GitHub. Built with ARCore 1.8 (Updated April 27, 2019)

Chapter 10

Download the companion Unity package from GitHub.