diff options
author | Ilia Mirkin <[email protected]> | 2017-08-14 23:38:52 -0400 |
---|---|---|
committer | Ilia Mirkin <[email protected]> | 2017-08-15 22:54:40 -0400 |
commit | 08f72a89444caa9b0851c8ea6458d44ecacec478 (patch) | |
tree | f701a3d31c2cfef91bdd8abb861f3f5bfd067233 /src/gallium | |
parent | 978c4c597aa48e65bd6822a85e6b8f82ca9281f1 (diff) |
a2xx: add logicop support
This passes both gl-1.0-logicop and gl-1.1-xor piglits.
Signed-off-by: Ilia Mirkin <[email protected]>
Diffstat (limited to 'src/gallium')
-rw-r--r-- | src/gallium/drivers/freedreno/a2xx/fd2_blend.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/gallium/drivers/freedreno/a2xx/fd2_blend.c b/src/gallium/drivers/freedreno/a2xx/fd2_blend.c index f063ebed66a..eae47ad061f 100644 --- a/src/gallium/drivers/freedreno/a2xx/fd2_blend.c +++ b/src/gallium/drivers/freedreno/a2xx/fd2_blend.c @@ -61,11 +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; - } + if (cso->logicop_enable) + rop = cso->logicop_func; /* 1:1 mapping with hw */ if (cso->independent_blend_enable) { DBG("Unsupported! independent blend state"); @@ -78,7 +77,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)) | |