summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/gallium/state_trackers/xorg/xorg_composite.c2
-rw-r--r--src/gallium/state_trackers/xorg/xorg_exa.c5
-rw-r--r--src/gallium/state_trackers/xorg/xorg_exa_tgsi.c14
3 files changed, 17 insertions, 4 deletions
diff --git a/src/gallium/state_trackers/xorg/xorg_composite.c b/src/gallium/state_trackers/xorg/xorg_composite.c
index 54b9ecaba1..90283fe6af 100644
--- a/src/gallium/state_trackers/xorg/xorg_composite.c
+++ b/src/gallium/state_trackers/xorg/xorg_composite.c
@@ -320,7 +320,7 @@ boolean xorg_composite_bind_state(struct exa_context *exa,
pDstPicture, pSrc, pMask, pDst);
setup_constant_buffers(exa, pDst);
- return FALSE;
+ return TRUE;
}
void xorg_composite(struct exa_context *exa,
diff --git a/src/gallium/state_trackers/xorg/xorg_exa.c b/src/gallium/state_trackers/xorg/xorg_exa.c
index 29785c0040..af76d6690f 100644
--- a/src/gallium/state_trackers/xorg/xorg_exa.c
+++ b/src/gallium/state_trackers/xorg/xorg_exa.c
@@ -506,7 +506,7 @@ ExaComposite(PixmapPtr pDst, int srcX, int srcY, int maskX, int maskY,
struct exa_pixmap_priv *priv = exaGetPixmapDriverPrivate(pDst);
#if DEBUG_PRINT
- debug_printf("\tExaComposite\n");
+ debug_printf("\tExaComposite(src[%d,%d], mask=[%d, %d], dst=[%d, %d], dim=[%d, %d])\n", srcX, srcY, maskX, maskY, dstX, dstY, width, height);
#endif
xorg_composite(exa, priv, srcX, srcY, maskX, maskY,
@@ -526,6 +526,9 @@ ExaCheckComposite(int op,
debug_printf("ExaCheckComposite(%d, %p, %p, %p) = %d\n",
op, pSrcPicture, pMaskPicture, pDstPicture, accelerated);
#endif
+#if DISABLE_ACCEL
+ accelerated = FALSE;
+#endif
return accelerated;
}
diff --git a/src/gallium/state_trackers/xorg/xorg_exa_tgsi.c b/src/gallium/state_trackers/xorg/xorg_exa_tgsi.c
index 8ce06e374a..8c9b674b4b 100644
--- a/src/gallium/state_trackers/xorg/xorg_exa_tgsi.c
+++ b/src/gallium/state_trackers/xorg/xorg_exa_tgsi.c
@@ -67,9 +67,19 @@ src_in_mask(struct ureg_program *ureg,
struct ureg_src src,
struct ureg_src mask)
{
- /* MUL dst, src, mask.wwww */
+#if 0
+ /* MUL dst, src, mask.a */
ureg_MUL(ureg, dst, src,
ureg_scalar(mask, TGSI_SWIZZLE_W));
+#else
+ /* MOV dst, src */
+ /* MUL dst.a, src.a, mask.a */
+ ureg_MOV(ureg, dst, src);
+ ureg_MUL(ureg,
+ ureg_writemask(dst, TGSI_WRITEMASK_W),
+ ureg_scalar(src, TGSI_SWIZZLE_W),
+ ureg_scalar(mask, TGSI_SWIZZLE_W));
+#endif
}
static struct ureg_src
@@ -271,7 +281,7 @@ create_vs(struct pipe_context *pipe,
if (has_mask) {
src = ureg_DECL_vs_input(ureg, input_slot++);
- dst = ureg_DECL_output(ureg, TGSI_SEMANTIC_GENERIC, 2);
+ dst = ureg_DECL_output(ureg, TGSI_SEMANTIC_GENERIC, 1);
ureg_MOV(ureg, dst, src);
}