KhronosGroup / KhronosGroup/glTF
Images used by textures with different color spaces?
- Dominant language
- HTML
- Stars
- 7.8k
- Forks
- 1.2k
- Avg merge
- 17h 26m
- Merged PRs (30d)
- 5
Description
The spec discusses image color spaces under [_Images, Section 3.8.3_](https://registry.khronos.org/glTF/specs/2.0/glTF-2.0.html#images):
> Effective transfer function (encoding) is defined by a glTF object that refers to the image (in most cases it’s a texture that is used by a material).
I believe this implies that the same _texture_ object cannot be associated with multiple color spaces, and so cannot be used both as a `baseColorTexture` and `occlusionTexture`. Would it be valid for the same _image_ object to be used by two textures in those material slots?
I've run into a question in glTF Transform, where it merges two identical textures, resulting in a color space difference in three.js (which expects 1 color space per glTF texture), and I'm not sure which is correct.
- https://github.com/donmccurdy/glTF-Transform/discussions/1061
Contributor guide
Research direction
Read the glTF 2.0 specification's Images, Section 3.8.3, then review the linked glTF Transform discussion and the reported three.js color-space behavior. Resolve whether one image may be referenced by textures with different color spaces and document the resulting guidance in the specification.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- three.js
- Domain
- computer-graphics, documentation
- Issue type
- Documentation
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 28/100