Unity Virtual Reality Projects
上QQ阅读APP看书,第一时间看更新

Publishing and importing using Google Poly

Fortunately, Google has made things a whole lot easier with the introduction of Google Poly (https://poly.google.com/) as a place to publish, browse, and download free 3D objects created with Google Tilt Brush and Google Blocks (and other apps that create OBJ files with materials).

I don't mean to sound like a Google fanboy, but let's stick to the Tilt Brush theme. Within Tilt Brush, it is very easy to publish your sketches to Google Poly with the click of a button. And importing Poly models into Unity is equally easy with the Poly Toolkit Unity package available on the Asset Store. Let's go through it:

Poly is not just for Unity developers. Google provides SDK for access from many platforms. See https://developers.google.com/poly/.

  1. Within Tilt Brush, first, ensure that you are logged into your Google account (My Profile).
  2. On the Save menu panel, choose the cloud upload option, as shown. This will upload your sketch to Poly.
  1. Then complete the publishing step in your browser (out of VR), and press Publish.

Note that Poly Toolkit includes the Tilt Brush Toolkit. If you already imported the Tilt Brush toolkit into your project from the previous section, we suggest you delete it (and the third-party folders) first before importing Poly to avoid conflict.

In Unity:

  1. Open the Asset Store panel (Window | Asset Store)
  2. Search for Poly Toolkit, then Download and Import the Poly Toolkit asset package into your project (https://assetstore.unity.com/packages/templates/systems/poly-toolkit-104464)
  3. Note that the toolkit installs a new Poly menu in the Unity menu bar. Choose Poly | Browse Assets… to open the Poly browser panel, as shown:

  1. This panel can be docked in the Unity editor by dragging its tab
  2. Before you can browse your own uploads, you must sign in using the Sign In button in the upper right
  3. Then, in the Poly Toolkit panel's Show selection, choose Your Uploads
  4. Locate the model you wish to import. Its page includes a number of import options, including scaling and recentering the model transform
  5. Choose Import Into Project
  6. By default, it will import the model into the Project Assets/Poly/Assets/ folder as a prefab
  7. Drag the model's prefab from the folder into your scene

That's it. You now have a world of 3D models at your fingertips: ones you created and published on Poly and others you've discovered on Poly, the Unity Asset store, or the plethora of other 3D model sites you can explore.