anv: fix color write enable interaction with color mask
authorLionel Landwerlin <lionel.g.landwerlin@intel.com>
Mon, 14 Mar 2022 07:52:35 +0000 (09:52 +0200)
committerMarge Bot <emma+marge@anholt.net>
Thu, 24 Mar 2022 10:49:07 +0000 (10:49 +0000)
commit1d250b7b959d2a206280e4f83db05780a83e0927
tree0115e8156790e6127d793886b1f2db9d14030dd1
parenta4f502de3228ec37dfcaa38225077ec3709d74ea
anv: fix color write enable interaction with color mask

Color writes & color masks occupy the same fields in the BLEND_STATE
structure. So we need to store color mask (which are not dynamic) on
the pipeline to merge that information with color writes.

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Fixes: b15bfe92f7f8 ("anv: implement VK_EXT_color_write_enable")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6111
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15310>
src/intel/vulkan/anv_pipeline.c
src/intel/vulkan/anv_private.h
src/intel/vulkan/genX_pipeline.c
src/intel/vulkan/gfx7_cmd_buffer.c
src/intel/vulkan/gfx8_cmd_buffer.c