{
void (*raster)(DrawablePtr, GCPtr, int mode, int n, DDXPointPtr pt);
- DBG(("%s x %d, width=%d, fill=%d, line=%d\n",
- __FUNCTION__, n, gc->lineWidth, gc->fillStyle, gc->lineStyle));
+ DBG(("%s x %d, width=%d, fill=%d [solid? %d], line=%d [solid? %d], bpp=%d\n",
+ __FUNCTION__, n, gc->lineWidth,
+ gc->fillStyle, gc->fillStyle == FillSolid,
+ gc->lineStyle, gc->lineStyle == LineSolid,
+ drawable->bitsPerPixel));
if (gc->lineWidth == 0) {
raster = fbZeroLine;
{
void (*raster)(DrawablePtr drawable, GCPtr gc, int n, xSegment * seg);
- DBG(("%s x %d, width=%d, fill=%d, line=%d\n",
- __FUNCTION__, n, gc->lineWidth, gc->fillStyle, gc->lineStyle));
+ DBG(("%s x %d, width=%d, fill=%d [solid? %d], line=%d [solid? %d], bpp=%d\n",
+ __FUNCTION__, n, gc->lineWidth,
+ gc->fillStyle, gc->fillStyle == FillSolid,
+ gc->lineStyle, gc->lineStyle == LineSolid,
+ drawable->bitsPerPixel));
if (gc->lineWidth == 0) {
raster = fbZeroSegment;
fbGetDrawable(drawable, dst, dstStride, dstBpp, dstXoff, dstYoff);
bitsStride = dstStride * (sizeof(FbBits) / sizeof(BITS));
- bitsBase =
- ((BITS *) dst) + (yoff + dstYoff) * bitsStride + (xoff + dstXoff);
+ bitsBase = ((BITS *) dst) + (yoff + dstYoff) * bitsStride + (xoff + dstXoff);
+
+ DBG(("%s: processing %ld clip boxes\n", __FUNCTION__, (long)(last_clip - clip)));
do {
INT32 *pt = (INT32 *)pt_0;
int n = n_0;
INT32 ul = coordToInt(clip->x1 - xoff, clip->y1 - yoff);
INT32 lr = coordToInt(clip->x2 - xoff - 1, clip->y2 - yoff - 1);
+ DBG(("%s: clip box=(%d, %d), (%d, %d)\n", __FUNCTION__, clip->x1, clip->y1, clip->x2, clip->y2));
+
pt1 = *pt++; n--;
pt2 = *pt++; n--;
for (;;) {
intToX(pt2) + xoff, intToY(pt2) + yoff,
n == 0 && gc->capStyle != CapNotLast, &dashoffset);
if (!n)
- return;
+ goto next_clip;
pt1 = pt2;
pt2 = *pt++;
pt2 != *((INT32 *)pt_0)) {
RROP(bits, and, xor);
}
- return;
+ goto next_clip;
}
pt1 = pt2;
pt2 = *pt++;
}
}
}
+next_clip: (void)clip;
} while (++clip != last_clip);
}
bitsBase =
((BITS *) dst) + (yoff + dstYoff) * bitsStride + (xoff + dstXoff);
+ DBG(("%s: processing %ld clip boxes\n", __FUNCTION__, (long)(last_clip - clip)));
do {
INT32 ul = coordToInt(clip->x1 - xoff, clip->y1 - yoff);
INT32 lr = coordToInt(clip->x2 - xoff - 1, clip->y2 - yoff - 1);
uint64_t *pt = (uint64_t *)seg_0;
int n = n_0;
+ DBG(("%s: clip box=(%d, %d), (%d, %d)\n", __FUNCTION__, clip->x1, clip->y1, clip->x2, clip->y2));
+
while (n--) {
union {
int32_t pt32[2];
} else
zero = true;
+ DBG(("%s: unclipped original extents: (%d, %d), (%d, %d)\n",
+ __FUNCTION__, box.x1, box.y1, box.x2, box.y2));
clipped = box32_trim_and_translate(&box, drawable, gc);
if (!box32_to_box16(&box, out))
return 0;
+ DBG(("%s: extents: (%d, %d), (%d, %d), clipped? %d\n",
+ __FUNCTION__, out->x1, out->y1, out->x2, out->y2, clipped));
return 1 | clipped << 1 | zero << 2;
}
goto fallback;
}
- DBG(("%s: fill=_%d [%d], line=%d [%d], join=%d [%d], mask=%lu [%d]\n",
+ DBG(("%s: fill=%d [%d], line=%d [%d], join=%d [%d], mask=%lu [%d]\n",
__FUNCTION__,
gc->fillStyle, gc->fillStyle == FillSolid,
gc->lineStyle, gc->lineStyle == LineSolid,
}
fallback:
- DBG(("%s: fallback\n", __FUNCTION__));
+ DBG(("%s: fallback, clip=%ldx[(%d, %d), (%d, %d)]\n", __FUNCTION__,
+ (long)RegionNumRects(gc->pCompositeClip),
+ gc->pCompositeClip->extents.x1, gc->pCompositeClip->extents.y1,
+ gc->pCompositeClip->extents.x2, gc->pCompositeClip->extents.y2));
region.data = NULL;
if (!region_maybe_clip(®ion, gc->pCompositeClip))
return;
+ DBG(("%s: CPU region=%ldx[(%d, %d), (%d, %d)]\n", __FUNCTION__,
+ (long)RegionNumRects(®ion),
+ region.extents.x1, region.extents.y1,
+ region.extents.x2, region.extents.y2));
if (!sna_gc_move_to_cpu(gc, drawable, ®ion))
goto out;
if (!sna_drawable_move_region_to_cpu(drawable, ®ion,
if (changes & (GCClipMask|GCSubwindowMode) ||
drawable->serialNumber != (gc->serialNumber & DRAWABLE_SERIAL_BITS) ||
- (gc->clientClipType != CT_NONE && (changes & (GCClipXOrigin | GCClipYOrigin))))
+ (gc->clientClipType != CT_NONE && (changes & (GCClipXOrigin | GCClipYOrigin)))) {
+ DBG(("%s: recomputing clip\n", __FUNCTION__));
miComputeCompositeClip(gc, drawable);
+ DBG(("%s: composite clip=%ldx[(%d, %d), (%d, %d)]\n",
+ __FUNCTION__,
+ (long)RegionNumRects(gc->pCompositeClip),
+ gc->pCompositeClip->extents.x1,
+ gc->pCompositeClip->extents.y1,
+ gc->pCompositeClip->extents.x2,
+ gc->pCompositeClip->extents.y2));
+ }
sna_gc(gc)->changes |= changes;
}