[Scummvm-cvs-logs] SF.net SVN: scummvm:[41883] scummvm/trunk/engines/kyra/screen_hof.cpp
lordhoto at users.sourceforge.net
lordhoto at users.sourceforge.net
Thu Jun 25 21:58:18 CEST 2009
Revision: 41883
http://scummvm.svn.sourceforge.net/scummvm/?rev=41883&view=rev
Author: lordhoto
Date: 2009-06-25 19:58:17 +0000 (Thu, 25 Jun 2009)
Log Message:
-----------
Change Screen_HoF::generateGrayOverlay to use a Palette object internally.
Modified Paths:
--------------
scummvm/trunk/engines/kyra/screen_hof.cpp
Modified: scummvm/trunk/engines/kyra/screen_hof.cpp
===================================================================
--- scummvm/trunk/engines/kyra/screen_hof.cpp 2009-06-25 19:57:35 UTC (rev 41882)
+++ scummvm/trunk/engines/kyra/screen_hof.cpp 2009-06-25 19:58:17 UTC (rev 41883)
@@ -45,7 +45,7 @@
}
void Screen_HoF::generateGrayOverlay(const uint8 *srcPal, uint8 *grayOverlay, int factor, int addR, int addG, int addB, int lastColor, bool flag) {
- uint8 tmpPal[768];
+ Palette tmpPal(lastColor);
for (int i = 0; i != lastColor; i++) {
if (flag) {
@@ -63,7 +63,7 @@
}
for (int i = 0; i < lastColor; i++)
- grayOverlay[i] = findLeastDifferentColor(tmpPal + 3 * i, srcPal, lastColor);
+ grayOverlay[i] = findLeastDifferentColor(tmpPal.getData() + 3 * i, srcPal, lastColor);
}
void Screen_HoF::cmpFadeFrameStep(int srcPage, int srcW, int srcH, int srcX, int srcY, int dstPage, int dstW,
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