[Scummvm-cvs-logs] CVS: scummvm/scumm bomp.cpp,2.9,2.10

Max Horn fingolfin at users.sourceforge.net
Thu Jun 19 10:51:11 CEST 2003


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

Modified Files:
	bomp.cpp 
Log Message:
the _bompBitsTable really tells the number of 1 bits in a given byte

Index: bomp.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/bomp.cpp,v
retrieving revision 2.9
retrieving revision 2.10
diff -u -d -r2.9 -r2.10
--- bomp.cpp	19 Jun 2003 16:03:12 -0000	2.9
+++ bomp.cpp	19 Jun 2003 17:50:18 -0000	2.10
@@ -329,7 +329,7 @@
 	}
 }
 
-static byte _bompBitsTable[] = {
+static const byte bitCount[] = {
 	8, 7, 7, 6, 7, 6, 6, 5, 7, 6, 6, 5, 6, 5, 5, 4,
 	7, 6, 6, 5, 6, 5, 5, 4, 6, 5, 5, 4, 5, 4, 4, 3,
 	7, 6, 6, 5, 6, 5, 5, 4, 6, 5, 5, 4, 5, 4, 4, 3,
@@ -382,7 +382,7 @@
 	count = (size + 7) >> 3;
 	while (count--) {
 		tmp = *scaling++;
-		ret_value += _bompBitsTable[tmp];
+		ret_value += bitCount[tmp];
 	}
 
 	return ret_value;





More information about the Scummvm-git-logs mailing list