summaryrefslogtreecommitdiff
path: root/fb
diff options
context:
space:
mode:
Diffstat (limited to 'fb')
-rw-r--r--fb/fbcompose.c12
-rw-r--r--fb/fbgc.c20
-rw-r--r--fb/fbglyph.c8
3 files changed, 23 insertions, 17 deletions
diff --git a/fb/fbcompose.c b/fb/fbcompose.c
index dd030d927..4938f89d0 100644
--- a/fb/fbcompose.c
+++ b/fb/fbcompose.c
@@ -1,5 +1,5 @@
/*
- * $XFree86: xc/programs/Xserver/fb/fbcompose.c,v 1.17 2003/11/03 05:11:00 tsi Exp $
+ * $XFree86: xc/programs/Xserver/fb/fbcompose.c,v 1.18 2003/12/04 17:15:12 tsi Exp $
*
* Copyright © 2000 Keith Packard, member of The XFree86 Project, Inc.
*
@@ -2424,6 +2424,8 @@ fbStore_external (FbCompositeOperand *op, CARD32 value)
(*op[2].store) (&op[2], value & 0xff000000);
}
+#define dummyScreen screenInfo.screens[0]
+
CARD32
fbFetch_transform (FbCompositeOperand *op)
{
@@ -2445,7 +2447,7 @@ fbFetch_transform (FbCompositeOperand *op)
case PictFilterNearest:
y = xFixedToInt (v.vector[1]) + op->u.transform.top_y;
x = xFixedToInt (v.vector[0]) + op->u.transform.left_x;
- if (POINT_IN_REGION (0, op->clip, x, y, &box))
+ if (POINT_IN_REGION (dummyScreen, op->clip, x, y, &box))
{
(*op[1].set) (&op[1], x, y);
bits = (*op[1].fetch) (&op[1]);
@@ -2469,7 +2471,7 @@ fbFetch_transform (FbCompositeOperand *op)
xerr = xFixed1 - xFixedFrac (v.vector[0]);
for (x = minx; x <= maxx; x++)
{
- if (POINT_IN_REGION (0, op->clip, x, y, &box))
+ if (POINT_IN_REGION (dummyScreen, op->clip, x, y, &box))
{
(*op[1].set) (&op[1], x, y);
bits = (*op[1].fetch) (&op[1]);
@@ -2527,7 +2529,7 @@ fbFetcha_transform (FbCompositeOperand *op)
case PictFilterNearest:
y = xFixedToInt (v.vector[1]) + op->u.transform.left_x;
x = xFixedToInt (v.vector[0]) + op->u.transform.top_y;
- if (POINT_IN_REGION (0, op->clip, x, y, &box))
+ if (POINT_IN_REGION (dummyScreen, op->clip, x, y, &box))
{
(*op[1].set) (&op[1], x, y);
bits = (*op[1].fetcha) (&op[1]);
@@ -2551,7 +2553,7 @@ fbFetcha_transform (FbCompositeOperand *op)
xerr = xFixed1 - xFixedFrac (v.vector[0]);
for (x = minx; x <= maxx; x++)
{
- if (POINT_IN_REGION (0, op->clip, x, y, &box))
+ if (POINT_IN_REGION (dummyScreen, op->clip, x, y, &box))
{
(*op[1].set) (&op[1], x, y);
bits = (*op[1].fetcha) (&op[1]);
diff --git a/fb/fbgc.c b/fb/fbgc.c
index 28c58a673..1e9eb5aa3 100644
--- a/fb/fbgc.c
+++ b/fb/fbgc.c
@@ -21,7 +21,7 @@
* TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $XFree86: xc/programs/Xserver/fb/fbgc.c,v 1.12 2001/05/29 04:54:09 keithp Exp $ */
+/* $XFree86: xc/programs/Xserver/fb/fbgc.c,v 1.15 2003/12/18 15:25:41 alanh Exp $ */
#include "fb.h"
#ifdef IN_MODULE
@@ -253,17 +253,19 @@ fbValidateGC(GCPtr pGC, unsigned long changes, DrawablePtr pDrawable)
}
if (changes & GCStipple)
{
- if (pGC->stipple &&
- (FbEvenStip (pGC->stipple->drawable.width,
- pDrawable->bitsPerPixel) ||
- fbCanEvenStipple (pGC->stipple, pDrawable->bitsPerPixel)))
- {
- pPriv->evenStipple = TRUE;
+ pPriv->evenStipple = FALSE;
+
+ if (pGC->stipple) {
+
+ /* can we do an even stipple ?? */
+ if (FbEvenStip (pGC->stipple->drawable.width,
+ pDrawable->bitsPerPixel) &&
+ (fbCanEvenStipple (pGC->stipple, pDrawable->bitsPerPixel)))
+ pPriv->evenStipple = TRUE;
+
if (pGC->stipple->drawable.width * pDrawable->bitsPerPixel < FB_UNIT)
fbPadPixmap (pGC->stipple);
}
- else
- pPriv->evenStipple = FALSE;
}
/*
* Recompute reduced rop values
diff --git a/fb/fbglyph.c b/fb/fbglyph.c
index f8f2179d5..3ad8d2507 100644
--- a/fb/fbglyph.c
+++ b/fb/fbglyph.c
@@ -1,5 +1,5 @@
/*
- * $XFree86: xc/programs/Xserver/fb/fbglyph.c,v 1.12 2001/09/07 15:16:00 keithp Exp $
+ * $XFree86: xc/programs/Xserver/fb/fbglyph.c,v 1.13 2003/12/04 17:15:12 tsi Exp $
*
* Copyright © 1998 Keith Packard
*
@@ -25,6 +25,8 @@
#include "fb.h"
#include "fontstruct.h"
#include "dixfontstr.h"
+
+#define dummyScreen screenInfo.screens[0]
Bool
fbGlyphIn (RegionPtr pRegion,
@@ -34,7 +36,7 @@ fbGlyphIn (RegionPtr pRegion,
int height)
{
BoxRec box;
- BoxPtr pExtents = REGION_EXTENTS (0, pRegion);
+ BoxPtr pExtents = REGION_EXTENTS (dummyScreen, pRegion);
/*
* Check extents by hand to avoid 16 bit overflows
@@ -51,7 +53,7 @@ fbGlyphIn (RegionPtr pRegion,
box.x2 = x + width;
box.y1 = y;
box.y2 = y + height;
- return RECT_IN_REGION (0, pRegion, &box) == rgnIN;
+ return RECT_IN_REGION (dummyScreen, pRegion, &box) == rgnIN;
}
#ifdef FB_24BIT