summaryrefslogtreecommitdiff
path: root/exa
diff options
context:
space:
mode:
authorMichel Dänzer <michel@tungstengraphics.com>2007-10-04 11:38:01 +0200
committerMichel Dänzer <michel@tungstengraphics.com>2007-10-04 11:44:03 +0200
commit3549a1282365e69e70c7c2546cfa7d25923cce31 (patch)
tree8623d9cbf8335d5ae9b79fc0ff5b59baf3117d4f /exa
parent604ebb5a6de372e6a8a96e0ee997db7929126860 (diff)
EXA: Disable 1x1 pixmap fill optimization for drivers that handle pixmaps.
This reverts commit 1365aeff5499a051375e43a9fcbf54733ac93929. It defeated the optimization for drivers that don't provide a CreatePixmap hook. The optimization makes no sense for drivers that do anyway, so disable it for them completely.
Diffstat (limited to 'exa')
-rw-r--r--exa/exa_accel.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/exa/exa_accel.c b/exa/exa_accel.c
index e10bf5cf2..8bbf036e4 100644
--- a/exa/exa_accel.c
+++ b/exa/exa_accel.c
@@ -1134,23 +1134,22 @@ exaFillRegionSolid (DrawablePtr pDrawable,
(*pExaScr->info->DoneSolid) (pPixmap);
exaMarkSync(pDrawable->pScreen);
- if (pDrawable->width == 1 && pDrawable->height == 1 &&
+ if (!(pExaScr->info->flags & EXA_HANDLES_PIXMAPS) &&
+ pDrawable->width == 1 && pDrawable->height == 1 &&
pDrawable->bitsPerPixel != 24) {
ExaPixmapPriv(pPixmap);
- exaPrepareAccess(pDrawable, EXA_PREPARE_DEST);
switch (pDrawable->bitsPerPixel) {
case 32:
- *(CARD32*)pPixmap->devPrivate.ptr = pixel;
+ *(CARD32*)pExaPixmap->sys_ptr = pixel;
break;
case 16:
- *(CARD16*)pPixmap->devPrivate.ptr = pixel;
+ *(CARD16*)pExaPixmap->sys_ptr = pixel;
break;
case 8:
- *(CARD8*)pPixmap->devPrivate.ptr = pixel;
+ *(CARD8*)pExaPixmap->sys_ptr = pixel;
}
- exaFinishAccess(pDrawable, EXA_PREPARE_DEST);
REGION_UNION(pScreen, &pExaPixmap->validSys, &pExaPixmap->validSys,
pRegion);
}