Setting up the scene and folders

Next, replace the default Main Camera object with Vuforia's ARCamera prefab:

  1. Delete the Main Camera object from Hierarchy.
  2. Locate the ARCamera prefab in the Project Assets/Vuforia/Prefabs folder and select and drag it to the Hierarchy.
  3. Use Add Component to add a Camera Settings component to ARCamera.
  4. Save the scene as SolarSystem (File | Save Scene As) and save the project (File | Save Project).

For this walkthrough, we are going to target Android devices. We can do some basic settings now. This way, you can periodically carry out a build and run to see your progress on the actual device throughout the project:

  1. Go to File | Build Settings.
  2. Set Switch Platform to Android.
  3. Also, add the curret scene and press Add Open Scenes.
  4. Choose Player Settings, then set your Identification Package name (com.Company.Product) and Minimum API Level (Android 5.1).
  5. Save the scene, then save the project.

At this point, if you press the Play button in the Unity editor, you should see the video feed from the webcam. This will allow you to debug AR applications inside the Unity editor.

It's useful if we now create some empty folders in the project's Assets folder which we will use soon:

  1. In the Project window, select the top-level Assets/ folder.
  2. Create a new folder in Assets/, named SolarSystem.
  3. Within Assets/SolarSystem/, create three more new folders: Textures, Scripts, and Materials.

The resulting project's Assets folders are shown in the following screenshot:

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset