The usual maps
glTF provides these textures for a material [1]:
| Map | What it controls | Note |
|---|---|---|
| Base colour | colour and pattern, e.g. wood grain, a label | colour image |
| Metallic-roughness | metalness (blue channel) and roughness (green channel) | data image, linear |
| Normal | fine surface structure without extra triangles | tangent space |
| Occlusion | shading in corners and joints (red channel) | see ambient occlusion |
| Emissive | self-lit areas, e.g. displays, LEDs | colour image |
One export detail matters: colour textures such as base colour and emissive are stored in sRGB, data textures such as metallic-roughness linearly [1]. Mix them up and surfaces look too bright, too dark or wrongly glossy.
Normal maps: detail without geometry
A normal map changes how light falls on each pixel without changing the shape. Grooves, embossing, weave or chequer plate look three-dimensional although the surface stays flat. That saves a lot of triangles. If the model has no tangents, the viewer calculates them with a defined method (MikkTSpace) [1].
Where maps come from
- photos and scans of real surfaces;
- material libraries;
- baking from a detailed model, for example normal and occlusion maps [2].
Size and memory
Every texture occupies its decompressed size on the graphics card, however small the JPEG was. GPU-compressed formats reduce this, but according to MDN they generally suit colours only, not normals [3]. Plan per material which maps are really needed and at what resolution; for GPU formats see KTX2.
From our library: the model of the office chair (example configurator, fictional product) uses colour and normal textures for upholstery and plastic parts.