aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/miext/shadow/shrotpackYX.h
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2012-03-23 10:05:55 +0100
committermarha <marha@users.sourceforge.net>2012-03-23 10:05:55 +0100
commit0f834b91a4768673833ab4917e87d86c237bb1a6 (patch)
tree363489504ed4b2d360259b8de4c9e392918e5d02 /xorg-server/miext/shadow/shrotpackYX.h
parentfc72edebf875378459368c5383d9023730cbca54 (diff)
downloadvcxsrv-0f834b91a4768673833ab4917e87d86c237bb1a6.tar.gz
vcxsrv-0f834b91a4768673833ab4917e87d86c237bb1a6.tar.bz2
vcxsrv-0f834b91a4768673833ab4917e87d86c237bb1a6.zip
libX11 xserver fontconfig mesa pixman xkbcomp xkeyboard-config git update
23 Mar 2012
Diffstat (limited to 'xorg-server/miext/shadow/shrotpackYX.h')
-rw-r--r--xorg-server/miext/shadow/shrotpackYX.h151
1 files changed, 73 insertions, 78 deletions
diff --git a/xorg-server/miext/shadow/shrotpackYX.h b/xorg-server/miext/shadow/shrotpackYX.h
index d7b01ec2a..57fcf22fa 100644
--- a/xorg-server/miext/shadow/shrotpackYX.h
+++ b/xorg-server/miext/shadow/shrotpackYX.h
@@ -54,107 +54,102 @@
#endif
void
-FUNC (ScreenPtr pScreen,
- shadowBufPtr pBuf);
+ FUNC(ScreenPtr pScreen, shadowBufPtr pBuf);
void
-FUNC (ScreenPtr pScreen,
- shadowBufPtr pBuf)
+FUNC(ScreenPtr pScreen, shadowBufPtr pBuf)
{
- RegionPtr damage = shadowDamage(pBuf);
- PixmapPtr pShadow = pBuf->pPixmap;
- int nbox = RegionNumRects (damage);
- BoxPtr pbox = RegionRects (damage);
- FbBits *shaBits;
- Data *shaBase, *shaLine, *sha;
- FbStride shaStride, winStride;
- int shaBpp;
- _X_UNUSED int shaXoff, shaYoff;
- int x, y, w, h;
- Data *winBase, *win, *winLine;
- CARD32 winSize;
-
- fbGetDrawable (&pShadow->drawable, shaBits, shaStride, shaBpp, shaXoff, shaYoff);
+ RegionPtr damage = shadowDamage(pBuf);
+ PixmapPtr pShadow = pBuf->pPixmap;
+ int nbox = RegionNumRects(damage);
+ BoxPtr pbox = RegionRects(damage);
+ FbBits *shaBits;
+ Data *shaBase, *shaLine, *sha;
+ FbStride shaStride, winStride;
+ int shaBpp;
+ _X_UNUSED int shaXoff, shaYoff;
+ int x, y, w, h;
+ Data *winBase, *win, *winLine;
+ CARD32 winSize;
+
+ fbGetDrawable(&pShadow->drawable, shaBits, shaStride, shaBpp, shaXoff,
+ shaYoff);
shaBase = (Data *) shaBits;
- shaStride = shaStride * sizeof (FbBits) / sizeof (Data);
+ shaStride = shaStride * sizeof(FbBits) / sizeof(Data);
winBase = (Data *) (*pBuf->window) (pScreen, 0, 0,
- SHADOW_WINDOW_WRITE,
- &winSize, pBuf->closure);
+ SHADOW_WINDOW_WRITE,
+ &winSize, pBuf->closure);
winStride = (Data *) (*pBuf->window) (pScreen, 1, 0,
- SHADOW_WINDOW_WRITE,
- &winSize, pBuf->closure) - winBase;
+ SHADOW_WINDOW_WRITE,
+ &winSize, pBuf->closure) - winBase;
- while (nbox--)
- {
+ while (nbox--) {
x = pbox->x1;
y = pbox->y1;
w = (pbox->x2 - pbox->x1);
h = pbox->y2 - pbox->y1;
- shaLine = shaBase + (y * shaStride) + x;
+ shaLine = shaBase + (y * shaStride) + x;
#ifdef PREFETCH
- __builtin_prefetch (shaLine);
+ __builtin_prefetch(shaLine);
#endif
- winLine = winBase + WINSTART(x, y);
+ winLine = winBase + WINSTART(x, y);
- while (h--)
- {
- sha = shaLine;
- win = winLine;
+ while (h--) {
+ sha = shaLine;
+ win = winLine;
- while (sha < (shaLine + w - 16))
- {
+ while (sha < (shaLine + w - 16)) {
#ifdef PREFETCH
- __builtin_prefetch (sha + shaStride);
+ __builtin_prefetch(sha + shaStride);
#endif
- *win = *sha++;
- win += WINSTEPX(winStride);
- *win = *sha++;
- win += WINSTEPX(winStride);
- *win = *sha++;
- win += WINSTEPX(winStride);
- *win = *sha++;
- win += WINSTEPX(winStride);
-
- *win = *sha++;
- win += WINSTEPX(winStride);
- *win = *sha++;
- win += WINSTEPX(winStride);
- *win = *sha++;
- win += WINSTEPX(winStride);
- *win = *sha++;
- win += WINSTEPX(winStride);
-
- *win = *sha++;
- win += WINSTEPX(winStride);
- *win = *sha++;
- win += WINSTEPX(winStride);
- *win = *sha++;
- win += WINSTEPX(winStride);
- *win = *sha++;
- win += WINSTEPX(winStride);
-
- *win = *sha++;
- win += WINSTEPX(winStride);
- *win = *sha++;
- win += WINSTEPX(winStride);
- *win = *sha++;
- win += WINSTEPX(winStride);
- *win = *sha++;
- win += WINSTEPX(winStride);
+ *win = *sha++;
+ win += WINSTEPX(winStride);
+ *win = *sha++;
+ win += WINSTEPX(winStride);
+ *win = *sha++;
+ win += WINSTEPX(winStride);
+ *win = *sha++;
+ win += WINSTEPX(winStride);
+
+ *win = *sha++;
+ win += WINSTEPX(winStride);
+ *win = *sha++;
+ win += WINSTEPX(winStride);
+ *win = *sha++;
+ win += WINSTEPX(winStride);
+ *win = *sha++;
+ win += WINSTEPX(winStride);
+
+ *win = *sha++;
+ win += WINSTEPX(winStride);
+ *win = *sha++;
+ win += WINSTEPX(winStride);
+ *win = *sha++;
+ win += WINSTEPX(winStride);
+ *win = *sha++;
+ win += WINSTEPX(winStride);
+
+ *win = *sha++;
+ win += WINSTEPX(winStride);
+ *win = *sha++;
+ win += WINSTEPX(winStride);
+ *win = *sha++;
+ win += WINSTEPX(winStride);
+ *win = *sha++;
+ win += WINSTEPX(winStride);
}
- while (sha < (shaLine + w))
- {
- *win = *sha++;
- win += WINSTEPX(winStride);
+ while (sha < (shaLine + w)) {
+ *win = *sha++;
+ win += WINSTEPX(winStride);
}
- y++;
- shaLine += shaStride;
- winLine += WINSTEPY();
+ y++;
+ shaLine += shaStride;
+ winLine += WINSTEPY();
}
pbox++;
- } /* nbox */
+ } /* nbox */
}