summaryrefslogtreecommitdiff
path: root/cfb/cfbsetsp.c
diff options
context:
space:
mode:
authorKaleb Keithley <kaleb@freedesktop.org>2003-11-25 19:29:01 +0000
committerKaleb Keithley <kaleb@freedesktop.org>2003-11-25 19:29:01 +0000
commitadc7f9a4ebdfe11d4cd6de9388b63dfe36450b39 (patch)
tree23eb7becc5360b2cbe16aa8d45529880067f3989 /cfb/cfbsetsp.c
parent90f1536dd315cd265bfc7ef35058761a65a01734 (diff)
XFree86 4.3.99.16 Bring the tree up to date for the Cygwin folksxf86-4_3_99_16
Diffstat (limited to 'cfb/cfbsetsp.c')
-rw-r--r--cfb/cfbsetsp.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/cfb/cfbsetsp.c b/cfb/cfbsetsp.c
index 2096d4e34..4f7dfaee1 100644
--- a/cfb/cfbsetsp.c
+++ b/cfb/cfbsetsp.c
@@ -45,7 +45,7 @@ ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
SOFTWARE.
******************************************************************/
-/* $XFree86: xc/programs/Xserver/cfb/cfbsetsp.c,v 3.5 2001/12/14 19:59:24 dawes Exp $ */
+/* $XFree86: xc/programs/Xserver/cfb/cfbsetsp.c,v 3.6 2003/10/29 22:44:53 tsi Exp $ */
#include "X.h"
#include "Xmd.h"
@@ -83,16 +83,18 @@ cfbSetScanline(y, xOrigin, xStart, xEnd, psrc, alu, pdstBase, widthDst, planemas
int w; /* width of scanline in bits */
register int *pdst; /* where to put the bits */
register int tmpSrc; /* scratch buffer to collect bits in */
- int dstBit; /* offset in bits from beginning of
- * word */
int offSrc;
int nl;
#if PSZ == 24
register char *psrcb, *pdstb;
register int xIndex;
#else
+ int dstBit; /* offset in bits from beginning of
+ * word */
register int nstart; /* number of bits from first partial */
+#if PSZ != 32 || PPW != 1
register int nend; /* " " last partial word */
+#endif
int startmask, endmask, nlMiddle;
#endif
DeclareMergeRop()
@@ -110,7 +112,6 @@ cfbSetScanline(y, xOrigin, xStart, xEnd, psrc, alu, pdstBase, widthDst, planemas
offSrc = (xStart - xOrigin) & PIM;
#endif
w = xEnd - xStart;
- dstBit = xStart & PIM;
#if PSZ == 24
nl = w;
@@ -125,6 +126,7 @@ cfbSetScanline(y, xOrigin, xStart, xEnd, psrc, alu, pdstBase, widthDst, planemas
pdstb += 3;
}
#else /* PSZ == 24 */
+ dstBit = xStart & PIM;
if (dstBit + w <= PPW)
{
maskpartialbits(dstBit, w, startmask);
@@ -139,10 +141,12 @@ cfbSetScanline(y, xOrigin, xStart, xEnd, psrc, alu, pdstBase, widthDst, planemas
nstart = PPW - dstBit;
else
nstart = 0;
+#if PSZ != 32 || PPW != 1
if (endmask)
nend = xEnd & PIM;
else
nend = 0;
+#endif
if (startmask)
{
getbits(psrc, offSrc, nstart, tmpSrc);