summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/intel/vulkan/genX_pipeline.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/intel/vulkan/genX_pipeline.c b/src/intel/vulkan/genX_pipeline.c
index 82fdf206a95..10efe542106 100644
--- a/src/intel/vulkan/genX_pipeline.c
+++ b/src/intel/vulkan/genX_pipeline.c
@@ -1351,10 +1351,10 @@ has_color_buffer_write_enabled(const struct anv_pipeline *pipeline,
if (binding->set != ANV_DESCRIPTOR_SET_COLOR_ATTACHMENTS)
continue;
- const VkPipelineColorBlendAttachmentState *a =
- &blend->pAttachments[binding->index];
+ if (binding->index == UINT32_MAX)
+ continue;
- if (binding->index != UINT32_MAX && a->colorWriteMask != 0)
+ if (blend->pAttachments[binding->index].colorWriteMask != 0)
return true;
}