anv: Don't use bogus alpha swizzles
authorJason Ekstrand <jason.ekstrand@intel.com>
Wed, 1 Feb 2017 20:27:59 +0000 (12:27 -0800)
committerJason Ekstrand <jason.ekstrand@intel.com>
Wed, 1 Feb 2017 22:41:06 +0000 (14:41 -0800)
commitccdd5b3738ef23dc69f322b9deab290cfaa1d0c5
tree403fa1fb0948bf3734e9056389f63c9681436db4
parent752ae38a0981f5799f2445fced4f19cbcab8baad
anv: Don't use bogus alpha swizzles

For RGB formats in Vulkan, we use the corresponding RGBA format with a
swizzle of RGB1.  While this swizzle is exactly what we want for
texturing, it's not allowed for rendering according to the docs.  While
we haven't been getting hangs or anything, we should probably obey the
docs.  This commit just sanitizes all render swizzles so that the alpha
channel maps to ALPHA.

Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
src/intel/vulkan/anv_blorp.c
src/intel/vulkan/anv_private.h
src/intel/vulkan/genX_cmd_buffer.c