[xserver-commit] xserver/fb fbpict.c,1.27,1.28 fbcompose.c,1.18,1.19
Jaymz Julian
xserver-commit@pdx.freedesktop.org
Sun, 28 Dec 2003 04:58:02 -0800
Committed by: jaymz
Update of /cvs/xserver/xserver/fb
In directory pdx:/tmp/cvs-serv26558/fb
Modified Files:
fbpict.c fbcompose.c
Log Message:
C++ comments -> C comments
Index: fbpict.c
===================================================================
RCS file: /cvs/xserver/xserver/fb/fbpict.c,v
retrieving revision 1.27
retrieving revision 1.28
diff -u -d -r1.27 -r1.28
--- fbpict.c 28 Dec 2003 12:42:33 -0000 1.27
+++ fbpict.c 28 Dec 2003 12:58:00 -0000 1.28
@@ -169,8 +169,9 @@
*destptr++=((((drb>>8) + dstrb) & 0x00FF00FF) | ((((dag>>8) + dstag) << 8) & 0xFF00FF00)); \
}
-// Note: this macro expects 5 bits of alpha, not 8!
-// (single op can actually be changed to take 6 bits, but double op can't)
+/* Note: this macro expects 5 bits of alpha, not 8!
+ * (single op can actually be changed to take 6 bits, but double op can't)
+ */
#define fastCombine0565(alpha, source, destval, destptr) { \
CARD16 dstrb = destval & 0xf81f; CARD16 dstg = destval & 0x7e0; \
CARD32 drb = ((source&0xf81f)-dstrb)*alpha; CARD32 dg=((source & 0x7e0)-dstg)*alpha; \
@@ -385,7 +386,7 @@
while (height--)
{
- // fixme: cleanup unused
+ /* fixme: cleanup unused */
unsigned int wt,wd;
CARD32 workingiDest;
CARD32 *widst;
@@ -1085,7 +1086,7 @@
-// macros for "i can't believe it's not fast" packed pixel handling
+/* macros for "i can't believe it's not fast" packed pixel handling */
#define alphamaskCombine24(a,b) genericCombine24(a,b,maskAlpha,maskiAlpha)
void
fbCompositeTrans_0888xnx0888(CARD8 op,
@@ -1114,13 +1115,15 @@
if (!maskAlpha)
return;
- //if (maskAlpha == 0xff)
- //{
- //fbCompositeSrc_0888x0888 (op, pSrc, pMask, pDst,
- // xSrc, ySrc, xMask, yMask, xDst, yDst,
- // width, height);
- //return;
- //}
+ /*
+ if (maskAlpha == 0xff)
+ {
+ fbCompositeSrc_0888x0888 (op, pSrc, pMask, pDst,
+ xSrc, ySrc, xMask, yMask, xDst, yDst,
+ width, height);
+ return;
+ }
+ */
fbComposeGetStart (pSrc, xSrc, ySrc, CARD8, srcStride, srcLine, 3);
fbComposeGetStart (pDst, xDst, yDst, CARD8, dstStride, dstLine, 3);
@@ -1132,8 +1135,8 @@
CARD32 rs, rd, nd;
CARD8 *isrc;
- // are xSrc and xDst at the same alignment? if not, we need to be complicated :)
- //if(0==0)
+ /* are xSrc and xDst at the same alignment? if not, we need to be complicated :)*/
+ /* if(0==0) */
if( (((xSrc*3)&3)!=((xDst*3)&3)) || ((srcStride&3)!=(dstStride&3)))
{
while (height--)
@@ -1146,13 +1149,13 @@
setupPackedReader(ws,wt,isrc,wsrc,workingSource);
- // get to word aligned
+ /* get to word aligned */
switch(!(int)dst&3)
{
case 1:
readPackedSource(rs);
- //*dst++=alphamaskCombine24(rs, *dst)>>8;
- rd=*dst; // make gcc happy. hope it doens't cost us too much performance
+ /* *dst++=alphamaskCombine24(rs, *dst)>>8; */
+ rd=*dst; /* make gcc happy. hope it doens't cost us too much performance*/
*dst++=alphamaskCombine24(rs, rd)>>8;
w--; if(w==0) break;
case 2:
@@ -1169,8 +1172,9 @@
wdst=(CARD32 *)dst;
while (w>3)
{
- // FIXME: write a special readPackedWord
- // macro, which knows how to halfword combine
+ /* FIXME: write a special readPackedWord macro, which knows how to
+ * halfword combine
+ */
#if IMAGE_BYTE_ORDER == LSBFirst
rd=*wdst;
@@ -1221,7 +1225,7 @@
src = srcLine;
srcLine += srcStride;
w = width*3;
- // get to word aligned
+ /* get to word aligned */
switch(!(int)src&3)
{
case 1:
@@ -1293,16 +1297,17 @@
int dstXoff, dstYoff;
int srcBpp;
int dstBpp;
- // these need to be signed now!
+ /* these need to be signed now! */
int iwidth=width;
int iheight=height;
int bytesPerPixel;
int initialWidth=width;
int initialX=xDst;
- // FIXME: this is possibly the second worst piece of code I've ever written.
- // (the worst being the previous imlementation of this)
- // -- jj
+ /* FIXME: this is possibly the second worst piece of code I've ever written.
+ * (the worst being the previous imlementation of this)
+ * -- jj
+ */
Bool srcRepeat=pSrc->repeat;
CARD32 srcHeight=pSrc->pDrawable->height;
@@ -1345,7 +1350,7 @@
memcpy( idst + (yDst + j) * dstStride + ((xDst * bytesPerPixel)),
isrc + (ySrc + j) * srcStride + ((xSrc * bytesPerPixel)),
(wwidth*bytesPerPixel));
- // reset the xSrc pointer. D'oh.
+ /* reset the xSrc pointer. D'oh. */
xSrc=0;
if(!srcRepeat)
iwidth=0;
@@ -1356,7 +1361,7 @@
}
}
ySrc=0;
- // reset the ySrc pointer. D'oh.
+ /* reset the ySrc pointer. D'oh. */
if(!srcRepeat)
iheight=0;
else
@@ -1631,9 +1636,10 @@
}
n = REGION_NUM_RECTS (®ion);
pbox = REGION_RECTS (®ion);
- // FIXME: this is bascially a "white list" of composites that work
- // with repeat until they are all implented. Once that's done, we
- // remove the checks below entirely
+ /* FIXME: this is bascially a "white list" of composites that work
+ * with repeat until they are all implented. Once that's done, we
+ * remove the checks below entirely
+ */
if(func==fbCompositeSrcSrc_nxn)
{
srcRepeat=maskRepeat=FALSE;
Index: fbcompose.c
===================================================================
RCS file: /cvs/xserver/xserver/fb/fbcompose.c,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -d -r1.18 -r1.19
--- fbcompose.c 18 Dec 2003 12:19:47 -0000 1.18
+++ fbcompose.c 28 Dec 2003 12:58:00 -0000 1.19
@@ -1649,7 +1649,7 @@
FbBits *line = op->u.drawable.line; CARD32 offset = op->u.drawable.offset;
CARD8 *pixel = ((CARD8 *) line) + (offset >> 3);
#if IMAGE_BYTE_ORDER == MSBFirst
- // FIXME: implent WORKING_UNALIGNED_INT for this endian :)
+ /* FIXME: implent WORKING_UNALIGNED_INT for this endian :) */
return (0xff000000 |
(pixel[0] << 16) |
(pixel[1] << 8) |