Asset Pipeline: Exporting PBR Textured 3D Models for AR/VR

Step by Step guide to exporting PBR textured 3D models for use in AR/VR

Here’s a handy guide on how to properly export PBR (physically based rendering) textured models and import them successfully into your AR/VR projects. I’ll show you some best practices and go over my PBR workflow.

If you want to learn the basics of 3D modeling or import a 3D object using traditional materials, I suggest checking out my previous guide here.

Software

This is a list of what I currently use to produce and export 3D models with PBR materials. If you prefer other software packages, by all means use what you’re comfortable with. Just follow the guide to make sure you’re exporting the 3D model correctly.

Autodesk Maya 2018 (Free Trial) — Industry standard 3D modeling software for many years but no longer the king of the hill. There are many other software packages I use depending on the type of model I make, but this has a great exporting tool (Game Exporter) which has made it easy for me to export complex FBX models that work well with rendering platforms.

Substance Painter (Free Trial) — The most widely used PBR creation tool with lots of knobs and limitless controls of your textures. There’s plenty of resources to get started quickly.

Viro Media (Free) — developer platform for building AR/VR applications. Great tool for visualizing assets in AR or VR and for iterative AR/VR design.

Best Practices

It doesn’t matter what you use to create or get your 3D model, it just needs to be optimized for real-time use and exported to an OBJ or FBX format, the most widely supported formats. I prefer exporting to FBX, because you can embed multiple animations and yields the most consistent and predictable results.

3D Resources

If you’re not creating a 3D model from scratch, there are several great sites that have quality realtime models to download:

www.sketchfab.com | www.turbosquid.com | www.poly.google.com|www.free3d.com | www.cgtrader.com

I also frequently post free 3D assets for use in AR/VR apps here -> Viro 3D Assets

PBR Texture Specs

Metallic Roughness Shader — The most commonly used PBR shader is Metallic Roughness. Make sure when you create a PBR template, set it to Metallic Roughness and not Specular Glossiness.

Size Efficiency — Since the models will be loaded into mobile AR/VR, texture memory will be very limited compared to desktops. PBR uses more textures than traditional texturing so don’t create 2k textures for every object and see where you can downsize dimensions.

Supported PBR Textures — Using Viro as the renderer, current supported textures are Albedo, Normal, Metallic, Roughness, and AO (Ambient Occlusion). Support for Height and Emissive is coming soon.

PBR Workflow

Cylinder textured within Substance Painter

For this guide, I created a quick sci-fi cylinder. You can grab it here.

Substance Painter Settings

New Project Settings

When first creating a Substance project, make sure PBR — Metallic Roughness (allegorithmic) is selected in the Template dropdown

is selected in the Template dropdown Then choose the mesh that will be worked on

Normal map format — OpenGL

Document resolution — I usually work on 2048 and since Painter is non-destructive, I can up-res or down-res the textures when I export

and since Painter is non-destructive, I can up-res or down-res the textures when I export If there’s no pre-made textures to import, hit OK and begin painting PBR textures

Export Textures

After creating my PBR textures within Painter, it’s now time to export them.

Export Document Settings

Go to File > Export Textures

> The Export Document popup will appear. Define where textures should be saved to in the top button

Make sure the Config has Document Channels + Normal + AO selected. This is selected because the default choice does not generate a separate AO texture.

selected. This is selected because the default choice does not generate a separate AO texture. Under Texture sets, select document size. In this case, I changed it to 1024x1024

Hit Export and find textures in the defined directory

Maya Export

Cylinder in Maya Viewport

Open Maya then open the cylinder mesh. At this point there’s no textures assigned, so we need to get them defined

Go to Windows > Rendering Editors > Hypershade

> > Within the Hypershade window, under Create, I select Stingray PBS. Stingray PBS is a very popular PBR shader that works well with rendering engines.

Important: Make sure your material starts with the prefix: “StingrayPBS” for it to appear properly within the Viro Renderer.

Singray PBS Property Editor

Under the Stingray PBS Property Editor > Attributes, select all the maps that will be used. In this case, select Use Color Map, Use Normal Map, Use Metallic Map, Use Roughness Map, Use AO Map.

Point to all your PBR maps

Then, scroll down and assign all the maps under Textures. Use *_Normal_OpenGL for normal map and disregard height map for this guide. Once all the textures are assigned, the cylinder in the viewport should appear properly w/ all its textures

Use *_Normal_OpenGL for normal map and disregard height map for this guide. Once all the textures are assigned, the cylinder in the viewport should appear properly w/ all its textures Now the mesh is ready for export. Go to File > Game Exporter

Game Exporter Window

Under Geometry , check Smoothing Groups and leave the other choices blank unless otherwise needed

, check and leave the other choices blank unless otherwise needed Under Settings , make sure Export to Single File is selected (unless you’re exporting multiple objects), Up Axis set to to Y and Embed Media is checked. Under FBX version, leave it on FBX 2018

, make sure is selected (unless you’re exporting multiple objects), set to to and is checked. Under FBX version, leave it on Under Path , set directory to save to in Path: and name the exported FBX underneath

, set directory to save to in and name the exported FBX underneath Click Export when ready! The 3D object should now be ready for use.

Visualizing 3D Assets AR/VR

Final rendered model

Viro Media has a PBR guide to help you import your PBR-enabled object into a AR/VR renderer -> ViroCore PBR Guide | ViroReact PBR Guide