From b43ce6768dcaa143f143bda59beb7794cc6bd7b3 Mon Sep 17 00:00:00 2001 From: Jason Ekstrand Date: Fri, 20 Nov 2015 11:52:54 -0800 Subject: [PATCH] gen8/pipeline: Set IndependentAlphaBlendEnable properly --- src/vulkan/gen8_pipeline.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/vulkan/gen8_pipeline.c b/src/vulkan/gen8_pipeline.c index 2baa5c5f31d..618774eda6e 100644 --- a/src/vulkan/gen8_pipeline.c +++ b/src/vulkan/gen8_pipeline.c @@ -204,6 +204,12 @@ emit_cb_state(struct anv_pipeline *pipeline, for (uint32_t i = 0; i < info->attachmentCount; i++) { const VkPipelineColorBlendAttachmentState *a = &info->pAttachments[i]; + if (a->srcBlendColor != a->srcBlendAlpha || + a->destBlendColor != a->destBlendAlpha || + a->blendOpColor != a->blendOpAlpha) { + blend_state.IndependentAlphaBlendEnable = true; + } + blend_state.Entry[i] = (struct GEN8_BLEND_STATE_ENTRY) { .LogicOpEnable = info->logicOpEnable, .LogicOpFunction = vk_to_gen_logic_op[info->logicOp], -- 2.30.2