[Scummvm-cvs-logs] CVS: scummvm/saga gfx.cpp,1.42,1.43 interface.h,1.36,1.37 xref.txt,1.19,1.20

Torbjörn Andersson eriktorbjorn at users.sourceforge.net
Thu Jan 20 06:00:15 CET 2005


Update of /cvsroot/scummvm/scummvm/saga
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv13167

Modified Files:
	gfx.cpp interface.h xref.txt 
Log Message:
Use the kITEColor constants for the ITE mouse cursor. Ironically, this is
one case where the original didn't use its own colour constants, so I had
to add a new one, kITEColorLightGrey, for colour 4.


Index: gfx.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/gfx.cpp,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -d -r1.42 -r1.43
--- gfx.cpp	15 Jan 2005 13:41:57 -0000	1.42
+++ gfx.cpp	20 Jan 2005 13:59:12 -0000	1.43
@@ -29,6 +29,7 @@
 
 #include "saga/saga.h"
 #include "saga/gfx.h"
+#include "saga/interface.h"
 
 #include "common/system.h"
 
@@ -979,14 +980,17 @@
 
 void Gfx::setCursor() {
 	// Set up the mouse cursor
-	byte cursor_img[CURSOR_W * CURSOR_H] = {
-		0, 0, 0, 4, 0, 0, 0,
-		0, 0, 0, 4, 0, 0, 0,
-		0, 0, 0, 4, 0, 0, 0,
-		4, 4, 4, 2, 4, 4, 4,
-		0, 0, 0, 4, 0, 0, 0,
-		0, 0, 0, 4, 0, 0, 0,
-		0, 0, 0, 4, 0, 0, 0,
+	const byte A = kITEColorLightGrey;
+	const byte B = kITEColorWhite;
+
+	const byte cursor_img[CURSOR_W * CURSOR_H] = {
+		0, 0, 0, A, 0, 0, 0,
+		0, 0, 0, A, 0, 0, 0,
+		0, 0, 0, A, 0, 0, 0,
+		A, A, A, B, B, B, B,
+		0, 0, 0, A, 0, 0, 0,
+		0, 0, 0, A, 0, 0, 0,
+		0, 0, 0, A, 0, 0, 0,
 	};
 
 	_system->setMouseCursor(cursor_img, CURSOR_W, CURSOR_H, 3, 3, 0);

Index: interface.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/interface.h,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -d -r1.36 -r1.37
--- interface.h	19 Jan 2005 20:43:12 -0000	1.36
+++ interface.h	20 Jan 2005 13:59:12 -0000	1.37
@@ -92,11 +92,13 @@
 };
 
 enum ITEColors {
-	kITEColorBrightWhite = 0x1,
-	kITEColorGrey = 0xa,
-	kITEColorDarkGrey = 0xb,
+	kITEColorBrightWhite = 0x01,
+	kITEColorWhite = 0x02,
+	kITEColorLightGrey = 0x04,
+	kITEColorGrey = 0x0a,
+	kITEColorDarkGrey = 0x0b,
 	kITEColorGreen = 0xba,
-	kITEColorBlack = 0xf,
+	kITEColorBlack = 0x0f,
 	kITEColorBlue = 0x93
 };
 

Index: xref.txt
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/xref.txt,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -d -r1.19 -r1.20
--- xref.txt	18 Jan 2005 11:59:09 -0000	1.19
+++ xref.txt	20 Jan 2005 13:59:12 -0000	1.20
@@ -96,6 +96,20 @@
 ======
  sceneIndexTable           _scene->getSceneLUT()
 
+Main.h
+======
+BRIGHT_WHITE               kITEColorBrightWhite
+WHITE_02                   kITEColorWhite
+GREY_0A                    kITEColorGrey
+DK_GREY_0B                 kITEColorDarkGrey
+PITCH_BLACK                kITEColorBlack
+BLUE_93                    kITEColorBlue
+GREEB_BA                   kITEColorGreen
+
+Note that ScummVM's kITEColorLightGrey does not have any corresponding
+constant in the original SAGA engine. We use it for the ITE mouse cursor. See
+PtrData[] in Main.c and setCursor() in gfx.cpp
+
 Tile.h
 ======
  isoTile.height            ISOTILE_ENTRY.tile_h





More information about the Scummvm-git-logs mailing list