WEBGI_materials_bumpmap glTF Extension
Contributors
- Palash Bansal, @repalash
Status
Draft.
Dependencies
Written against the glTF 2.0 spec.
Exclusions
- This extension must not be used on a material that also uses
KHR_materials_pbrSpecularGlossiness
. - This extension must not be used on a material that also uses
KHR_materials_unlit
. - This extension must not be used on a material that also uses
KHR_materials_volume
.
Overview
This extension adds support for setting bumpTexture
and bumpScale
.
bumpTexture
sets the bump map from the R
channel. The black and white values map to the perceived depth in relation to the lights. Bump doesn't actually affect the geometry of the object, only the lighting.
bumpScale
defines how much the bump map affects the material. Typical ranges are 0-1. Bump map is ignored if bumpScale == 0
Extending Materials
Sample values:
{
"materials": [
{
"extensions": {
"WEBGI_materials_bumpmap": {
"bumpScale": 0.6,
"bumpTexture": { "index": 1 },
}
}
}
]
}
Implementation details
Basic Implementation similar to three.js: bumpMap in MeshPhysicalMaterial Alternative implementation with Parallax Bump Mapping.
TODO: add technical details.
Known Implementations
Resources
- Simple Plane glTF with BumpMap: TODO.
- Parallax Mapping plugin sample: https://showcase.pixotronics.com/demos/plugins~parallax-mapping.html (TODO)