llvmpipe: blend has effects even if no colorbuffers.
authorDave Airlie <airlied@redhat.com>
Fri, 19 Jun 2020 06:57:41 +0000 (16:57 +1000)
committerDave Airlie <airlied@redhat.com>
Mon, 31 Aug 2020 03:20:11 +0000 (13:20 +1000)
ARB_framebuffer_no_attachments + multisampling means blend
can have an effect even outside of colorbufs

Fixes:
dEQP-VK.pipeline.multisample.alpha_to_coverage_no_color_attachment.samples_4.alpha_opaque

Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6381>

src/gallium/drivers/llvmpipe/lp_state_fs.c

index efb6bee25117cee68a96d9852717d544245e72e5..804ed9214c628936721f98c8012440bbcb5bf0d9 100644 (file)
@@ -3987,9 +3987,7 @@ make_variant_key(struct llvmpipe_context *lp,
       key->occlusion_count = TRUE;
    }
 
-   if (lp->framebuffer.nr_cbufs) {
-      memcpy(&key->blend, lp->blend, sizeof key->blend);
-   }
+   memcpy(&key->blend, lp->blend, sizeof key->blend);
 
    key->coverage_samples = 1;
    key->min_samples = 1;