The first step is to get your Assets into a format suitable for what you want to do. It’s very important to set up a proper workflow from your 3D modelling application, such as 3ds Max, Maya, Blender, and Houdini, into Unity. When exporting assets from 3D modelling applications for import into Unity, you need to consider:
Your project scale, and your preferred unit of measurement, play a very important role in a believable Scene. In many “real world” setups, we recommend you assume 1 Unity unit = 1 meter (100cm), because many physics systems assume this unit size. For more advice, see the Art Asset best practice guide.
To maintain consistency between your 3D modelling application and Unity, always validate the imported GameObject scale and size. 3D modelling applications have units and scale settings in the FBX export configuration (see the documentation for your 3D modelling software for configuration advice). Generally, the best way to match the scale when importing to Unity is to set these tools to work in centimeters, and export FBX at automatic scale. However, you should always check that the unit and scale settings match when starting a new project.
To quickly validate your export settings, In your 3D modelling application, create a simple 1x1x1m cube and import it into Unity. In Unity, create a default Cube (GameObject > 3D Object > Cube). This is 1x1x1m. Use this as a scale reference to compare with your imported model. These cubes should look identical when the Transform component’s Scale property is set to 1,1,1 in the Inspector:
When blocking out a Scene with placeholders or sketching geometry, having a point of reference scale model can be helpful. Choose a point of reference scale model that is appropriate for the Scene you’re making. In the Spotlight Tunnel Sample Scene case, we use a park bench:
Your Scene doesn’t have to use exactly the same proportions as real life. Using a point of reference scale model simply allows consistencies of scale to be relative between GameObjects, even if the Scene is intended to have exaggerated proportions.
The information inside a texture needs to contain the correct information to give a proper result when added to a Material. Texture authoring software, such as Photoshop and Substance Painter, outputs consistent and predictable textures when you configure them correctly.
Here’s an example of a pre-set configuration for Substance Painter to output textures for use with a Unity Standard Opaque material:
The texture assignment in the Unity Standard Material is:
|Output maps for export
|Assignment in Unity Standard Shader Material
|Assigned to Albedo.
|Assigned to Metallic and Occlusion.Smoothness Source set to Metallic Alpha.
|Assigned to Normal Map Slot.
Note: Packing multiple channels to a single texture, such as the MetallicAOGloss, saves texture memory compared to exporting Ambient Occlusion (AO) as a separate texture. This is the best way of working with a Unity Standard Material.
When creating textures, it’s important not to mix up the alpha channel. The example below shows how transparency in a PNG file can be confusing to author in Photoshop because of the way Photoshop deals with a PNG alpha channel (without using an external plugin). In this case, an uncompressed 32-bit TGA with a dedicated alpha channel might be a better option, assuming the source texture file size is not an issue:
The transparent PNG file shown above was created in Photoshop with its alpha channel coming through as a black value. The TGA with a dedicated alpha channel shows the expected value. As you can see above, when each texture assigned to the Standard Shader material reads smoothness data from the alpha channel, the smoothness of the material with PNG textures is unexpectedly inverted, while the smoothness of the material with TGA textures is normal.
Unity reads tangent space normal maps with the following interpretation:
For example, a 3ds Max Render to Texture normal map outputs the Green Channel Y+ as Down by default. This causes an inverted surface direction along the Y axis and creates invalid results when lit. To validate the normal map direction, create a simple plane with concave bevel (middle picture on the example below) and bake it to a flat plane. Then assign the baked normal map into a plane in Unity with identifiable light direction and see if any of the axes are inverted.
For advice on axis settings, refer to your 3D modelling application’s documentation.