Khronos Public Bugzilla
Bug 749 - Non-depth comparison and texture swizzle.
Non-depth comparison and texture swizzle.
Status: RESOLVED FIXED
Product: OpenGL
Classification: Unclassified
Component: API Specification
4.3
All All
: P3 normal
: ---
Assigned To: Jon Leech
ARB Next Generation API TSG email alias
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-10-27 15:03 PDT by Alfonse
Modified: 2013-10-04 03:58 PDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alfonse 2012-10-27 15:03:52 PDT
In section 15.2.1 of GL 4.3, it says:

"Texture lookups involving textures with depth component data generate a tex-ture base color Cb either using depth data directly or by performing a comparison with the Dref value used to perform the lookup, as described in section 8.22.1, and expanding the resulting value Rt to a color Cb = (Rt; 0; 0; 1). Swizzling is then performed as described above, but only the first component Cs[0] is re-turned to the shader."

It is not clear whether the last sentence is referring to *comparison* access alone or if *all* depth component accesses only return the first component. Depth texture accesses do return 4 values, but shadow accesses only return 1.

So... does swizzling work for non-shadow depth accesses or not?
Comment 1 Jon Leech 2013-08-08 16:33:18 PDT
We're actively looking at this now. The spec is unclear on swizzle behavior
in the non-comparison case so we need to figure out what implementations
have actually chosen to do before trying to resolve this. Thanks for the
report.
Comment 2 Jon Leech 2013-10-04 03:58:59 PDT
We've polled everyone and established that swizzling is performed for
all depth component accesses; a clarification to this effect will
appear in the next 4.4 spec update. Thanks!