KhronosGroup / KhronosGroup/glTF-Sample-Assets
StainedGlassLamp sample transmission-clearcoat conflict
- Dominant language
- TypeScript
- Stars
- 1.1k
- Forks
- 107
- Avg merge
- 9h 39m
- Merged PRs (30d)
- 4
Description
The StainedGlassLamp sample as found in the glTF folder uses the StainedGlassLamp_glass_transmission-clearcoat.png image for both transmission and clearcoat. However, the specification requires that both these textures use the red channel. Quote from the description text:
"The two textures for transmissionTexture and clearcoatTexture have been packed together into a single bitmap StainedGlassLamp_glass_transmission-clearcoat using the red and green channels to optimize memory use."
It is not even clearly stated which of them has been placed into the green channel, but it seems to be the clearcoat. Blender loads both transmission and clearcoat textures from the red channel; both channels happen to be very similar, so the issue can easily go unobserved.
Since conforming loaders will load these textures from the red channel, I think that there should be two separate images instead of the mentioned one: StainedGlassLamp_glass_transmission.png and StainedGlassLamp_glass_clearcoat.png, and the gltf file should be edited so it uses these images. The BasisU version probably has the same issue.
Contributor guide
Research direction
Start with the StainedGlassLamp sample in the glTF folder and inspect StainedGlassLamp_glass_transmission-clearcoat.png, the glTF file, and the corresponding BasisU version. Compare their texture-channel assignments with the quoted description and specification; done means the transmission and clearcoat textures use the required red-channel data and the sample assets reference the corrected images.
Written by the indexing model from the issue text.
Assessment
- Domain
- computer-graphics
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 58/100