[Scummvm-cvs-logs] CVS: scummvm/scumm gfx.cpp,2.69,2.70

Max Horn fingolfin at users.sourceforge.net
Sat May 3 20:09:53 CEST 2003


Update of /cvsroot/scummvm/scummvm/scumm
In directory sc8-pr-cvs1:/tmp/cvs-serv9631

Modified Files:
	gfx.cpp 
Log Message:
there ya go

Index: gfx.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/gfx.cpp,v
retrieving revision 2.69
retrieving revision 2.70
diff -u -d -r2.69 -r2.70
--- gfx.cpp	4 May 2003 03:05:16 -0000	2.69
+++ gfx.cpp	4 May 2003 03:08:52 -0000	2.70
@@ -1203,17 +1203,14 @@
 	int run = _vm->_egaStripRun[stripnr];
 	bool dither = false;
 	byte dither_table[128];
-	byte data = 0;
 	byte *ptr_dither_table;
-	int x = 8;
-	int y;
 	memset(dither_table, 0, sizeof(dither_table));	// FIXME - is that correct?
-	do {
+
+	for (int x = 0; x < 8; x++) {
 		ptr_dither_table = dither_table;
-		y = height;
-		do {
+		for (int y = 0; y < height; y++) {
 			if (--run == 0) {
-				data = *src++;
+				byte data = *src++;
 				if (data & 0x80) {
 					run = data & 0x7f;
 					dither = true;
@@ -1231,10 +1228,10 @@
 			}
 			*dst = *ptr_dither_table++;
 			dst += _vm->_realWidth;
-		} while (--y);
-		dst -= _vm->_realWidth * 128;
+		}
+		dst -= _vm->_realWidth * height;
 		dst++;
-	} while (--x);
+	}
 }
 
 void Gdi::decompressMaskImgOld(byte *dst, byte *src, int stripnr) {





More information about the Scummvm-git-logs mailing list