[Mesa-dev] [PATCH] a2xx: add logicop support
Ilia Mirkin
imirkin at alum.mit.edu
Tue Aug 15 03:40:59 UTC 2017
This passes both gl-1.0-logicop and gl-1.1-xor piglits.
Signed-off-by: Ilia Mirkin <imirkin at alum.mit.edu>
---
src/gallium/drivers/freedreno/a2xx/fd2_blend.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/src/gallium/drivers/freedreno/a2xx/fd2_blend.c b/src/gallium/drivers/freedreno/a2xx/fd2_blend.c
index f063ebed66a..d1187147c09 100644
--- a/src/gallium/drivers/freedreno/a2xx/fd2_blend.c
+++ b/src/gallium/drivers/freedreno/a2xx/fd2_blend.c
@@ -61,10 +61,10 @@ fd2_blend_state_create(struct pipe_context *pctx,
{
const struct pipe_rt_blend_state *rt = &cso->rt[0];
struct fd2_blend_stateobj *so;
+ unsigned rop = PIPE_LOGICOP_COPY;
if (cso->logicop_enable) {
- DBG("Unsupported! logicop");
- return NULL;
+ rop = cso->logicop_func;
}
if (cso->independent_blend_enable) {
@@ -78,7 +78,7 @@ fd2_blend_state_create(struct pipe_context *pctx,
so->base = *cso;
- so->rb_colorcontrol = A2XX_RB_COLORCONTROL_ROP_CODE(12);
+ so->rb_colorcontrol = A2XX_RB_COLORCONTROL_ROP_CODE(rop);
so->rb_blendcontrol =
A2XX_RB_BLEND_CONTROL_COLOR_SRCBLEND(fd_blend_factor(rt->rgb_src_factor)) |
--
2.13.0
More information about the mesa-dev
mailing list