[Scummvm-cvs-logs] SF.net SVN: scummvm:[40952] scummvm/trunk/engines/sci/gfx/res_pic.cpp

wjpalenstijn at users.sourceforge.net wjpalenstijn at users.sourceforge.net
Thu May 28 00:41:14 CEST 2009


Revision: 40952
          http://scummvm.svn.sourceforge.net/scummvm/?rev=40952&view=rev
Author:   wjpalenstijn
Date:     2009-05-27 22:41:14 +0000 (Wed, 27 May 2009)

Log Message:
-----------
SCI: Make standard EGA palette a part of gfx_sci0_pic_colors.
This fixes regressions in at least SQ3 and Iceman from r40870

Modified Paths:
--------------
    scummvm/trunk/engines/sci/gfx/res_pic.cpp

Modified: scummvm/trunk/engines/sci/gfx/res_pic.cpp
===================================================================
--- scummvm/trunk/engines/sci/gfx/res_pic.cpp	2009-05-27 21:25:45 UTC (rev 40951)
+++ scummvm/trunk/engines/sci/gfx/res_pic.cpp	2009-05-27 22:41:14 UTC (rev 40952)
@@ -123,7 +123,13 @@
 	if (!gfx_sci0_pic_colors) {
 		gfx_sci0_pic_colors = new Palette(256);
 		gfx_sci0_pic_colors->name = "gfx_sci0_pic_colors";
-		for (int i = 0; i < 256; i++) {
+		// TODO: Discover the exact purpose of gfx_sci0_pic_colors
+		// For now, we set the first 16 colours to the standard EGA palette,
+		// and fill the remaining entries with slight variations
+		for (int i = 0; i < 16; i++) {
+			gfx_sci0_pic_colors->setColor(i,gfx_sci0_image_colors[0][i].r, gfx_sci0_image_colors[0][i].g, gfx_sci0_image_colors[0][i].b);
+		}
+		for (int i = 16; i < 256; i++) {
 			byte r = INTERCOL(gfx_sci0_image_colors[sci0_palette][i & 0xf].r,
 			                  gfx_sci0_image_colors[sci0_palette][i >> 4].r);
 			byte g = INTERCOL(gfx_sci0_image_colors[sci0_palette][i & 0xf].g,


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list