KhronosGroup/glTF

What are the default values for texture samplers if nothing is provided in the file?

GasimGasimzada opened this issue · 3 comments

To take the infamous Damaged helmet model, it does not have any sampler data provided: https://github.com/KhronosGroup/glTF-Sample-Models/blob/master/2.0/DamagedHelmet/glTF/DamagedHelmet.gltf#L170

What should the renderer/application define as the default value when no sampler data is provided? Also, can we have these defaults documented? For example, materials have a default section that mention that all the default values of each property is used. I was also looking at the JSON schema of sampler and there are no default provided here as well.

Related:

Perhaps more could be said, but the defaults are intentionally not predetermined — applications may have good reason to make different choices here.

Filtering is currently implementation-specific (see the linked issue above) but wrapping modes are set to REPEAT by default: https://registry.khronos.org/glTF/specs/2.0/glTF-2.0.html#reference-sampler.

Makes sense thank you!