You are previewing Deconstructing Google Cardboard Apps.
O'Reilly logo
Deconstructing Google Cardboard Apps

Book Description

Google Cardboard is one of the most accessible ways to experience virtual reality today. This book introduces developers to this exciting new platform using both the Cardboard Android SDK and the Cardboard Unity SDK. From creating the ambiance and immersion of a virtual landscape, to using a smartphone camera to layer worlds with different filters, capturing and controlling speech, optimizing graphics, and even promoting your app in the Google Play store, this book will provide developers with everything they need to successfully build Google Cardboard applications.

This book shows developers how to create Google Cardboard apps, with authors deconstructing their successfully published Cardboard apps in the book, walking readers through concepts using their apps as examples.

Table of Contents

  1. Preface
    1. Introducing Google Cardboard
    2. What should you know prior to reading this book?
      1. Source code
    3. Authors
      1. Technical Reviewers
  2. 1. A VR Introduction
    1. The WOW! effect
    2. The “Huh” effect
    3. Why develop for Google Cardboard?
    4. Insights on the VR market
    5. My forecast for the next years
    6. Tooling and workflows
      1. Unity (5.1)
      2. 3D Authoring - Blender
      3. Makehuman
      4. About workflows
      5. Hardware
    7. What can VR bring that flat worlds cannot?
      1. Ambiance
      2. Immersion
      3. Presence and attachment
    8. The Cardboard platform
      1. Reality versus virtual reality
      2. The mobile platform
      3. The mobile VR adopters
      4. Hardware
      5. Restrictions / Limitations
  3. 2. Alien Apartment
    1. How did I come to develop Alien Apartment?
    2. Let’s build on this knowledge and craft a world!
      1. Setting things up
      2. Managing axis
      3. Kicking in stereo view
      4. Updating player azimuth
      5. Movement detection principle (triggering events with your head)
      6. Theory
      7. Implementation
      8. Usage
      9. Last considerations
      10. Making user interfaces and interactions without actual interfaces
    3. Basics
    4. Running an example
      1. Can I make a user interface out of it?
    5. Creating ambiance
      1. Skyboxes and the Lighting window
      2. Calling for emotions and memory
      3. Audio
      4. Music
      5. What have we done here?
    6. Miscellaneous tips and tricks
      1. Light-mapping
      2. Performance
      3. Clipping planes
      4. Batching
      5. Meshes merge
      6. Occlusion baking
      7. Playing with the brain
      8. Quality settings
      9. Physically-based Shader
      10. Fading
      11. Keystore
      12. Version control
      13. Awake(), Start(),...
      14. Generic coroutine management
      15. Building
      16. Exit on back key press
      17. Screen time-out
      18. Shaders
      19. Unlit with alpha
      20. Self-lit shader
      21. Glass shader
      22. Textured glass shader
    7. Summary
  4. 3. Glitcher VR
    1. Introduction to Glitcher VR
      1. Prior experience and motivation
    2. The challenges of VR development
    3. Glitcher VR Architecture Deconstructed
      1. Camera Subsystem
      2. Problems that need to be addressed by the camera subsystem
      3. Starting and stopping cameras
      4. Sending frames to the GPU for fast processing
    4. Creating a drawing surface
      1. Saving photos, capturing filtered frames, and video
      2. Automatically detecting and managing cameras with a camera manager
    5. Input subsystem
      1. Problems that need to be addressed by the input subsystem
      2. Detecting and handling input devices
      3. Speech as an input multiplexer
      4. Rendering and Filter System
      5. Design goals
      6. Basic filters
      7. Building complex filters from a base filter
      8. Rendering additional assets
      9. Filter manager
    6. Notification System
      1. Design goals
      2. Building a text renderer
      3. Building a basic notification
    7. Helper utilities and other features
      1. Torch/Flashlight
      2. Converting face bounding boxes to GLSL coordinates
      3. Sending face information to the filters
    8. Tips and Potential Improvements
      1. Improvements to input
      2. Avoid filler content
      3. Testing with ordinary users
      4. Testing on various hardware
      5. Memory management and using profiling tools
    9. Summary
  5. 4. Lanterns and a Village for Cardboard
    1. Common VR rendering techniques used in both apps
      1. Adapting a scene for VR
      2. Creating our own renderer
      3. Using renderer from the Cardboard SDK for Android
    2. Rendering a scene in the Lanterns VR app
      1. Fixed draw order optimization
      2. Fog and light shader
      3. Water reflection
      4. Night sky shader
    3. Rendering and optimizations tricks in the Village VR app
      1. Single draw-call smoke effects
      2. Point sprites for fireflies and snow
      3. Sorting objects by distance
      4. Frustum Culling
      5. Characters movement
      6. Reusing textures and atlasing
      7. Lightmaps packing
      8. Lightmap palettes
      9. Final Village Shaders
      10. Vegetation shaders
      11. Sky textures compression
    4. Summary
  6. 5. Google Cardboard - VR for the Masses
    1. The Google Cardboard project
    2. Getting started with Cardboard
      1. Previous Astronaut games
      2. The story of WAA! VR
    3. Getting started on WAA!
      1. Unity3D pro
      2. Testing device Nexus5
      3. Cardboard kits
      4. Asset development in Maxon Cinema4D R16
      5. Asset export: FBX or C4DtoUnity?
    4. The Google Cardboard Unity3D SDK
      1. Moving from .js to c\
    5. Interaction concepts
      1. The magnetic trigger
      2. Raycast collision testing
    6. UI, menus, and scene setup
      1. Skybox and “space” environment
      2. “Title” screen
      3. Main “Universe” menu
      4. In-game HUD
    7. Firing and hitting in VR space
      1. Adding “Asteroids” as targets
      2. Firing rockets
      3. VR 3D effect and the “zone”
      4. Avoiding VR sickness
    8. Special effects, polishing, and testing
      1. Everything looks better with particles
      2. Trail renderer
      3. Adding powerups
      4. Tweaking the gameplay parameters
      5. Adding the character’s body
    9. Launch and listen to the community
      1. Google’s calling
      2. SXSW, Google I/O
      3. Next steps: Oculus and iOS
      4. Thank you!