Materials

This section describes which of Unity’s material parameters are used when exporting USD.

Supported Materials by Render Pipeline

Render Pipeline

Shader

Built-In

Standard

URP

Universal Render Pipeline/LitUniversal Render Pipeline/Complex Lit (When using Clear Coat)

HDRP

HDRP/Lit

For each, the value is retrieved using the parameter name provided in the Shader. We recommend you use parameter names commonly used in Unity (_MainTex, _MetallicGlossMap, etc.) because then you may be able to get material parameters with other Shaders than what is listed.

Type of material to be exported to USD

Select Settings in the Omniverse menu to open the Omniverse Settings panel.
Material Type.
Select the material type in “Material Type”.

Material Type

Description

None

No material assignment

MDL

Assign OmniPBR or OmniGlass

UsdPreviewSurface

Assign UsdPreviewSurface

Note

MaterialX is not supported yet.

Built-In: Standard

In the Built-In Standard Shader, the following parameters outlined in red are the USD export targets.
Built-In material parameters.

Rendering Mode supports: * Opaque * Cutout * Transparent

Main Maps supports: * Albedo Color / Albedo Map * Metallic * Smoothness * Metallic/Smoothness Map * Normal Map * Occlusion Map * Emission Color / Emission Map * Texture transform: Tiling, Offset

Render Mode: Opaque

Assign Opaque to an solid shape.

Render Mode - Opaque.

Render Mode: Cutout

For shapes that involve trimming, such as tree leaves, assign Cutout.

Render Mode - Cutout.
In this example, the cutout is made according to the alpha value of the Albedo Map.
Alpha Cutoff is the threshold value.
Alpha Cutoff.

Render Mode: Transparent

Translucency is represented by Transparent for see-through shapes.
Render Mode - Transparent.
When passed to USD, Opacity is assigned.

Transparent uses the alpha channel of the Albedo Map and the alpha value of the Albedo color.

Specifying alpha in Albedo Color.
  • If the Albedo Map does not exist, the alpha value of the Albedo Color is output as the Opacity value of the USD.

  • If an Albedo Map exists and the alpha value of the Albedo Color is 1.0, the Alpha channel of the Albedo Map is used as the Opacity Map for USD (Opacity Mono Source=“mono_alpha” in OmniPBR).

  • If an Albedo Map exists and the alpha value of the Albedo Color is not 1.0, the Alpha channel of the Albedo Map is multiplied by the alpha value of the Albedo Color and used as the Opacity Map for USD (Opacity Mono Source=“mono_average” in OmniPBR).

Albedo

If both Albedo color and Albedo Map are present, they will appear multiplied in the USD export. In USD, the Albedo map and Albedo Color each have their own parameters.

Multiply Albedo Color.

Metallic/Smoothness Map

In Unity, Metallic/Smoothness and Occlusion maps are packed into one texture.
Occlusion is often a separate texture.

Channel

Property

Red

Metallic

Green

Occlusion

Blue

None

Alpha

Smoothness

Smoothness = 1.0 - Roughness

Smoothness and Roughness.

The Metallic/Smoothness map is decomposed into a USD metallic map and a roughness map.

If the Metallic/Smoothness Map is not specified, specify the Metallic and Smoothness values as numbers from 0.0-1.0.

Metallic and Smoothness parameters.

Normal Map

When specifying a Normal Map, the strength of the Normal can also be specified.

Normal Map parameter.

When exporting USD, if the material type is MDL, both Normal Map and NormalMap strength will be output.

If the material type is usdPreviewSurface, the strength value is ignored because it does not have a Normal Map strength parameter.

Occlusion Map

Occlusion Map is output when using UsdPreviewSurface as the material type for USD export.

Note

Occlusion Map output is not supported when OmniPBR is used.*

Occlusion Map parameter.

If an Occlusion value is specified (If not 1.0), the Occlusion Map and Occlusion value are baked into the texture and output.

Emission

When the Emission checkbox is checked, Emission Color and Emission Map can be specified.

Emission parameters.
If both are used, they are exported as a multiplied and baked texture.
It is also possible to specify a texture with HDRI (exr/hdr file) dynamic range as an Emission Map.

Texture transform: Tiling, Offset

If a texture is specified, the same values for “Tiling” and “Offset” are used for all textures.

Texture transform parameters.

Note

Secondary Maps in Unity are not used in the USD export.*

URP: Universal Render Pipeline/Lit

In the case of URP, the material is specified with parameters similar to those of the Built-In Standard.
Since there are a few differences, we will explain only the differences.
In the URP Lit Shader, the following red parameters are the USD export targets.
URP material parameters.
  • Base Color / Base Map

  • Metallic

  • Smoothness

  • Metallic/Smoothness Map

  • Normal Map

  • Occlusion Map

  • Emission Color / Emission Map

  • Texture transform : Tiling, Offset

Surface Type can be “Opaque” or “Transparent”.
Check Alpha Clipping to represent “Cutout”.
Alpha Clipping - Threshold.

Double Sided

If Render Face is set to “Both”, the double sided will be displayed in Unity.
Double sided.

Note

when exporting USD, Render Face information is not yet output. Currently, as a USD, it is always displayed on single sided. In Omniverse, it is always displayed double sided.*

HDRP HDRP/Lit

In the case of HDRP, the material is specified with parameters similar to those of the Built-In Standard. Since there are a few differences, we will explain only the differences.

In the HDRP Lit Shader, the following red parameters are the USD export targets.

HDRP material parameters.
  • Base Color / Base Map

  • Metallic

  • Smoothness

  • Mask Map (Metallic, Smoothness, Occlusion Map)

  • Normal Map

  • Emissive Color / Emissive Map

  • Texture transform: Tiling, Offset

In HDRP, specify Metallic, Smoothness, and Occlusion Map in Mask Map.

Surface Type can be “Opaque” or “Transparent”.
Check Alpha Clipping to represent “Cutout”.
Alpha Clipping - Threshold.

HDRP : Exporting OmniGlass

HDRP allows for glass representation using IOR with HDRP/Lit Shader. When specifying some parameters, OmniGlass is used when the material is MDL in the USD export.

Steps to specify materials for OmniGlass.
  1. Use HDRP

  2. SurfaceType = Transparent

  3. BaseMap.alpha = 0.0

  4. RefractionModel != None

In this case, OmniGlass is used in HDRP.

Parameters supported by HDRP’s Glass when exporting USD

The following parameters can be specified for Glass and are passed to OmniGlass in USD.
Material parameters for OmniGlass.
  • Smoothness

  • Index Of Refraction

  • Thickness

  • Transmittance Color (Color or Texture)

Below is the Transmittance Color and Texture specified in Unity.
Glass in Unity.
Exported to USD, imported into Omniverse Composer, and displayed in RTX-Real-Time as follows.
OmniGlass in USD Composer.
In Omniverse, the correct refraction is by ray tracing.

Clearcoat

When using “Universal Render Pipeline/Complex Lit” in Shader for URP and “HDRP/Lit” in Shader for HDRP, a Clearcoat of the material can be used.

Clearcoat in USD

Clearcoat in USD can be handled using UsdPreviewSurface. OmniPBR does not have Clearcoat parameters.

Clearcoat in USD Composer.

Two Clearcoat parameters exist for USD’s UsdPreviewSurface.

Parameter name

Default

Description

clearcoat

0.0

Clearcoat value (0.0-1.0)

clearcoatRoughness

0.01

Clearcoat roughness (0.0-1.0)

Both clearcoat and clearcoatRoughness can use float values or textures.

Clearcoat (URP)

For materials using the Universal Render Pipeline/Complex Lit in URP, the Clearcoat parameter can be used.
Clearcoat in Unity URP.
Two parameters exist in the Clearcoat of the URP.
Check the ClearCoat checkbox to use Clearcoat.

Parameter name

Description

Mask

Clearcoat value (0.0-1.0)

Smoothness

Clearcoat smoothness (0.0-1.0)

These two parameters can be textures as well as numbers.

The Mask Map in Unity has the following channel configuration.
[R] Mask
[G] Smoothness
[B] None
[A] None
USD’s clearcoatRoughness is converted to Unity’s ClearCoat Smoothness.
This can be calculated using the following formula.
> ClearCoat Smoothness = 1.0 - clearcoatRoughness

Clearcoat (HDRP)

Clearcoat in HDRP has only Coat Mask value.
The ClearCoat Smoothness that was present in URP is not present in HDRP and this is always treated as 1.0.
Clearcoat in Unity HDRP.

Parameter name

Description

Coat Mask

Clearcoat value (0.0-1.0)

In the Clearcoat Mask texture, Clearcoat Mask was set on the R, G, and B channels.

[R] Mask
[G] Mask
[B] Mask
[A] None

In Unity’s HDRP, the ClearCoat Mask Map seemed to reference only the R channel.

Color Space

  • Colors in Unity are often managed in sRGB.

  • In USD, colors are linear.

  • Color space is considered when specifying a single color or texture.

Color Space in Unity

There are multiple places to specify color space in Unity.

Project Settings

  • Select [Edit]-Project Settings from the menu.

  • In Player - Other Settings, under Rendering, you can select “Color Space.”

Color Space in Project Settings.
  • The default is “Linear”.

  • This unifies the rendering process with Linear.

  • This can be changed to “Gamma” for Built-In, but should be handled as “Linear.”

Texture

  • In the Inspector, when you select a texture in the Project window, if sRGB (Color Texture) is checked, the texture will be treated in sRGB.

sRGB in texture.
  • In Unity, textures representing “color,” such as Base Map (Diffuse Map) and Emissive Map, are generally handled in sRGB.

  • HDRIs such as hdr/exr are passed directly to the renderer as linear.

  • Normal maps, metallic and smoothness maps, etc., are not colors and are passed to the renderer as linear.

  • In Unity, textures are automatically converted to linear when passed to rendering.

  • Therefore, users and developers do not need to be aware of color space.

sRGB Color

For the color of the material, it is to be specified in sRGB.

sRGB Color.

The color (sRGB) specified in the Base Map can be confirmed to be the same color (sRGB) in the rendering result.

These complex differences in color space are unified linearly at rendering time (linear workflow), and the flow is converted to sRGB, which is appropriate for the display when it is displayed.

Color Space in USD

All colors in the USD format are linear and unified.

This conversion by color space is automatic in the Omniverse Unity Connector’s importer and exporter.

Linear Color

For color, it is converted and passed so that it is in a linear color space.

Linear Color in USD.

The exporter in the Omniverse Unity Connector converts sRGB colors on Unity to linear and passes them to USD. Importers in the Omniverse Unity Connector convert linear colors in USD to sRGB and pass them to Unity.

Texture

For each material texture, you can select auto/raw/sRGB as the color space.

Texture color space in USD.

The color space of this texture is specified as follows, as is the case on the Unity side.

Texture Type

Color Space

Albedo Map

sRGB (auto)

Emissive Color Map

sRGB (auto)

Normal Map

raw

Roughness Map

raw

Metallic Map

raw

Ambient Occlusion Map

raw

Opacity Map

sRGB (auto)

Note

The Opacity Map of a material exported from the Omniverse Unity Connector uses the A of the RGBA texture specified in the Albedo Map.