summaryrefslogtreecommitdiffstats
path: root/src/mapi/glapi
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2016-05-18 11:38:32 -0700
committerKenneth Graunke <[email protected]>2016-05-20 14:30:00 -0700
commit6e5d86c07af920fa52afbe075a04116b9ebb3cc3 (patch)
tree2411eaeef7535a69548fe88ee9464ea4fbb4c455 /src/mapi/glapi
parent12ab7fc6ac1ca785afb1126607bb95ea26473e06 (diff)
nir: Add a simple nir_lower_wpos_center() pass for Vulkan drivers.
nir_lower_wpos_ytransform() is great for OpenGL, which allows applications to choose whether their coordinate system's origin is upper left/lower left, and whether the pixel center should be on integer/half-integer boundaries. Vulkan, however, has much simpler requirements: the pixel center is always half-integer, and the origin is always upper left. No coordinate transform is needed - we just need to add <0.5, 0.5>. This means that we can avoid using (and setting up) a uniform. I thought about adding more options to nir_lower_wpos_ytransform(), but making a new pass that never even touched uniforms seemed simpler. v2: Use normal iterator rather than _safe variant (noticed by Matt). Signed-off-by: Kenneth Graunke <[email protected]> Acked-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/mapi/glapi')
0 files changed, 0 insertions, 0 deletions