MaterialX to glTF

The following are some examples of conversions from MaterialX to glTF. The input files are from the resources folder of the ASWF MaterialX Repository found here. the glTF and Autodesk
Standard Surface example scenes are converted. For the latter shader translation and texture baking are performed. All results are packaged into
individual glTF binary files (glb).

These files can be previewed in any integration which accepts glb files as input such as the ThreeJS editor, and the Babylon viewer.

For this page the model-viewer package is used. Note that materials with transmission do not render well with this viewer (e.g. the "glass shaders").

glTF PBR Shading Model Conversions

These materials directly use glTF PBR as the shading model

< Boombox < Car Paint < Default glTF PBR
< Glass < Gold < Plastic

"Standard Surface" Shading Model Conversions

These materials use Autodesk Standard Surface as the shading model and are hence converted to glTF PBR and then the upstream graph is "baked". This results in some loss of mappings currently including normal maps and incorrect 3d procedural. This is due to logic within the MaterialX core package itself and not this package.

All materials are mapped to a default "shader ball" geometry in glTF format.

MaterialX files with multiple materials are each converted and then packaged into a single GLB file for preview (such as the "Open Chess Set").

< Brass < Brick < Car Paint
< Open Chess Set < Chrome < Copper
< Default Standard Surface < Glass < Glass Tinted
< Gold < Grey < Grey Calibration
< Jade < Brass Tiled Look < Wood Tiled Look
< 3D Marble < Brushed Metal < Plastic
< Thin Film < Velvet < Wood Tiled

The following are examples materials from QuiltiX (0.5.0). This library uses QuiltiX by creating a custom script which calls into QuiltiX and extends the functionality by adding in glTF import and export menu items.
QuiltiX and MaterialX to use the MaterialX 1.38.9 definition library for OpenUSD was required. The results of a few examples which come with QuiltIX are shown.

< Black Uphostery < Motley Patchwork Run < Copper (Old)

The following is one of the examples running QuiltiX with the HDStorm OpenUSD render delegate and a local model-viewer customization.

These materials are from the "Physically Based" site maintained by Anton Palmqvist. The MaterialX files were downloaded from the Physical Based Site.

< Aluminum < Sapphire < Whiteboard < Tire

glTF to MaterialX

The following are renders performed using the MaterialX Viewer which comes with the MaterialX release.
The MaterialX material file and the original glTF geometry file are loaded into the viewer and rendered.

Open Chess Set Sci Fi Helmet Iridescence Lamp
glTF logo Damaged Helmet BoomBox with Axes
Flight Helmet Alpha Blend Test Vertex Color Test
Material Variant Texture Transform Test Unlit Shader Test

The same files can be loadded into any integration which accepts MaterialX files. Below is the the glTF Sample Model "Boombox with Axes" shown after conversion in the MaterialX "Node Graph" Editor.