[Scummvm-cvs-logs] CVS: scummvm/scumm gfx.cpp,1.56,1.57

James Brown ender at users.sourceforge.net
Sat Nov 9 02:00:01 CET 2002


Update of /cvsroot/scummvm/scummvm/scumm
In directory usw-pr-cvs1:/tmp/cvs-serv14278

Modified Files:
	gfx.cpp 
Log Message:
This should fix the DOTT white-background bug. Someone please confirm this for me :)


Index: gfx.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/gfx.cpp,v
retrieving revision 1.56
retrieving revision 1.57
diff -u -d -r1.56 -r1.57
--- gfx.cpp	8 Nov 2002 18:40:12 -0000	1.56
+++ gfx.cpp	9 Nov 2002 09:59:25 -0000	1.57
@@ -458,10 +458,20 @@
 
 	dest = _currentPalette;
 
-	for (i = 0; i < numcolor * 3; i++) {
-		*dest++ = *ptr++;
-	}
+	for (i = 0; i < numcolor; i++) {
+		r = *ptr++;
+		g = *ptr++;
+		b = *ptr++;
 
+		// This comparison might look wierd, but it's what the disassembly (DOTT) says!
+		if ((_features & GF_AFTER_V7) || (<= 15 || r < 252 || g < 252 || b < 252)) {
+			*dest++ = r;
+			*dest++ = g;
+			*dest++ = b;
+		} else {
+			dest += 3;
+		}
+	}
 	setDirtyColors(0, numcolor - 1);
 }
 





More information about the Scummvm-git-logs mailing list