Google Cardboard, Virtual Reality, VR

How to Build Google Cardboard VR Game using Unity part -1

unity_googlecardboard

Unity made it very easy to create VR apps, and with cardboard, it is just super easy.

Unity 5.1 onwards contains built-in support for certain VR devices, but for that, you require Unity pro licence.

 

So Why Cardboard ?

Because it is cheapest VR Device available in the market. it cost you only $10- $20, and you do not need Unity pro licence for that.

other options for virtual reality devices

Device NamePrice
Oculus Rift$599
HTC Vive$799
Gear VR$99

 

                                      

all are very expensive and some are not easily available to the user. On the other hand google Cardboard works with most modern Android phones and iPhone. Phones need to be running Android 4.1 (Jelly Bean) or above. Ideally should have a gyroscope, most important there are tons of apps available.

Prerequisites

  • Unity – At least v5.1 is recommended. I’m using Unity v5.3 Personal edition.
  • Windows or Mac – I’ll be using Mac in this tutorial.
  • Cardboard SDK for Unity – That link will download zip file named “cardboard-unity-master”.
  • Android SDK
  • A Google Cardboard style headset.
  • An Android device to put inside that headset.
  • Basic knowledge of Unity.

enough theory, let’s jump to code now

First  Download the latest Google Cardboard SDK for unity

Now follow these steps:

  1. Open Unity  — image                                                                                                                                                                                                     
  2. Create New Project                                                                                                                                                                                                                                                                        google_cardboard_Create_New_Project
  3. Import the SDK package: Assets > Import Package > Custom Package.                                                                                        google_cardboard_Import_PackageSelect the CardboardSDKForUnity unitypackage where you downloaded it and click Open. and click import                                                                                                                                                                                                                                                        Import_google_cardboardSDK
  4. Now delete the Main Camera from the hierarchy and save your scene                                                                                                                google_cardboard_MainCamera
  5. Now drag CardboardMain from prefabs folder to the hierarchy and save your scene                                                                                                                           
    drag_cardboardmain_tohierarchy
  6. Now drag CardboardReticle from  Assets > Cardboard > Prefabs > UI  to Cardboard > Head > Main Camera                                                                                                                                                                                                                                           
    drag_cardboardreticle

 

 

                   

One comment

  1. darkness reborn hack apk

    There’s apparently a package to understand about it. I suppose
    you made certain nice points in features also.

Comments are closed.