Setting up the project

We will use the sample project as a template for creating a new project. At the time of writing, doing an ARCore asset import with the beta version still requires considerable project setup. Ideally, we would like to create a project from scratch, but we will do the next best thing. The next best thing will be to clone the project from GitHub into a new folder of our choice. You can start by opening up Command Prompt and following these steps:

  1. Create a new folder off your root or working folder and download the ARCore template by executing the following commands:
mkdir ARCore
cd ARCore
git clone https://github.com/google-ar/arcore-unity-sdk.git ARCoreDesign
  1. This will create a new folder. Switch to it and download the project template from GitHub.
  2. Open up Unity to the project dialog and click on Open.
  3. Use the folder dialog to find and select the ARCoreDesign folder we just downloaded the code to, as shown in the following excerpt:

Opening the ARCoreDesign project
  1. Wait for Unity to load. Ensure that you watch for any compiler errors at the bottom of the editor status bar. If you see them, it means you may have a version conflict or that something's changed. Check your version and try to upgrade or downgrade, as needed.
  2. The first thing we will do is organize our folder structure. Create a new folder called ARCore_Design in the Project window by right-clicking (Ctrl + Click on Mac) on the Assets folder and selecting Create | Folder from the context menu.

 

  1. Directly underneath the new folder, add folders for Scripts, Prefabs, Scenes, Materials, and Models, as illustrated:
Setting up the folder structure

The technique we just used for setting up the project is useful when you are dealing with other sample projects you want to make your own. Unity manages a project by the folder and the name corresponds to the folder name. We won't worry about setting up source control as you can do this on your own, as you see fit.

If you are setting up this project for anything other than learning, you should definitely consider a source code solution at this point. Dropbox or other file sharing solutions will work in a pinch, but it's not something that will work for more than one developer. There are plenty of free and fairly simple solutions that work with Unity, so take some time and pick one that works for you.
..................Content has been hidden....................

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