summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2013-06-28 14:24:10 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2013-06-28 17:43:46 +0100
commit626b5e541663f838475eaef2c1bc3ae4d4848165 (patch)
tree4b44a261d0337cca3ecd2ad0a1691dc1f004b70e
parent2356579cdff36adf58fb69894f646a6e63053a15 (diff)
sna: Add debug control for disabling accelerated GetImage
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
-rw-r--r--src/sna/sna_accel.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/sna/sna_accel.c b/src/sna/sna_accel.c
index 53c8c8fb..6e71f7b0 100644
--- a/src/sna/sna_accel.c
+++ b/src/sna/sna_accel.c
@@ -77,6 +77,7 @@
#define ACCEL_FILL_SPANS 1
#define ACCEL_SET_SPANS 1
#define ACCEL_PUT_IMAGE 1
+#define ACCEL_GET_IMAGE 1
#define ACCEL_COPY_AREA 1
#define ACCEL_COPY_PLANE 1
#define ACCEL_COPY_WINDOW 1
@@ -14429,7 +14430,10 @@ sna_get_image(DrawablePtr drawable,
if (!fbDrawableEnabled(drawable))
return;
- DBG(("%s (%d, %d)x(%d, %d)\n", __FUNCTION__, x, y, w, h));
+ DBG(("%s: pixmap=%ld (%d, %d)x(%d, %d), format=%d, mask=%lx, depth=%d\n",
+ __FUNCTION__,
+ (long)get_drawable_pixmap(drawable)->drawable.serialNumber,
+ x, y, w, h, format, mask, drawable->depth));
region.extents.x1 = x + drawable->x;
region.extents.y1 = y + drawable->y;
@@ -14437,9 +14441,11 @@ sna_get_image(DrawablePtr drawable,
region.extents.y2 = region.extents.y1 + h;
region.data = NULL;
- can_blt = format == ZPixmap &&
- drawable->bitsPerPixel >= 8 &&
- PM_IS_SOLID(drawable, mask);
+ can_blt = (ACCEL_GET_IMAGE &&
+ !FORCE_FALLBACK &&
+ format == ZPixmap &&
+ drawable->bitsPerPixel >= 8 &&
+ PM_IS_SOLID(drawable, mask));
flags = MOVE_READ;
if ((w | h) == 1)