aboutsummaryrefslogtreecommitdiff
path: root/graphics
diff options
context:
space:
mode:
authorJody Northup2009-06-20 05:23:09 +0000
committerJody Northup2009-06-20 05:23:09 +0000
commitf7dd1c15ed38418a0371032966144eb6c2e004cb (patch)
treedc292bcaf9c657bd1db9efbc56195e70c578ea0e /graphics
parent8b6ed92376024f43876af93fdfccd72d6fc33ac0 (diff)
downloadscummvm-rg350-f7dd1c15ed38418a0371032966144eb6c2e004cb.tar.gz
scummvm-rg350-f7dd1c15ed38418a0371032966144eb6c2e004cb.tar.bz2
scummvm-rg350-f7dd1c15ed38418a0371032966144eb6c2e004cb.zip
renamed ENABLE_16BIT define to more accurate ENABLE_RGB_COLOR
svn-id: r41696
Diffstat (limited to 'graphics')
-rw-r--r--graphics/cursorman.cpp6
-rw-r--r--graphics/cursorman.h8
-rw-r--r--graphics/pixelformat.h4
3 files changed, 9 insertions, 9 deletions
diff --git a/graphics/cursorman.cpp b/graphics/cursorman.cpp
index 6446216867..865c7515f0 100644
--- a/graphics/cursorman.cpp
+++ b/graphics/cursorman.cpp
@@ -97,7 +97,7 @@ void CursorManager::popAllCursors() {
}
}
-#ifdef ENABLE_16BIT
+#ifdef ENABLE_RGB_COLOR
while (!_cursorFormatStack.empty()) {
PixelFormat *form = _cursorFormatStack.pop();
delete form;
@@ -116,7 +116,7 @@ void CursorManager::replaceCursor(const byte *buf, uint w, uint h, int hotspotX,
Cursor *cur = _cursorStack.top();
-#ifdef ENABLE_16BIT
+#ifdef ENABLE_RGB_COLOR
uint size = w * h * g_system->getScreenFormat().bytesPerPixel;
#else
uint size = w * h;
@@ -220,7 +220,7 @@ void CursorManager::replaceCursorPalette(const byte *colors, uint start, uint nu
}
}
-#ifdef ENABLE_16BIT
+#ifdef ENABLE_RGB_COLOR
void CursorManager::pushCursorFormat(PixelFormat format) {
// if (!g_system->hasFeature(OSystem::kFeatureCursorHasPalette))
// return;
diff --git a/graphics/cursorman.h b/graphics/cursorman.h
index 32f1b90f3e..b28145d932 100644
--- a/graphics/cursorman.h
+++ b/graphics/cursorman.h
@@ -28,7 +28,7 @@
#include "common/scummsys.h"
#include "common/stack.h"
#include "common/singleton.h"
-#ifdef ENABLE_16BIT
+#ifdef ENABLE_RGB_COLOR
#include "graphics/pixelformat.h"
#include "common/system.h"
#endif
@@ -134,7 +134,7 @@ public:
*/
void replaceCursorPalette(const byte *colors, uint start, uint num);
-#ifdef ENABLE_16BIT
+#ifdef ENABLE_RGB_COLOR
/**
* Push a new cursor pixel format onto the stack, and set it in the backend.
*
@@ -177,7 +177,7 @@ private:
uint _size;
Cursor(const byte *data, uint w, uint h, int hotspotX, int hotspotY, uint32 keycolor = 0xFFFFFFFF, int targetScale = 1, uint8 bitDepth = 8) {
-#ifdef ENABLE_16BIT
+#ifdef ENABLE_RGB_COLOR
{ //limit the lifespan of the format value to minimize impact on memory usage
Graphics::PixelFormat f = g_system->getScreenFormat();
_size = w * h * f.bytesPerPixel;
@@ -231,7 +231,7 @@ private:
};
Common::Stack<Cursor *> _cursorStack;
Common::Stack<Palette *> _cursorPaletteStack;
-#ifdef ENABLE_16BIT
+#ifdef ENABLE_RGB_COLOR
Common::Stack<Graphics::PixelFormat *> _cursorFormatStack;
#endif
};
diff --git a/graphics/pixelformat.h b/graphics/pixelformat.h
index 4ad1f8b400..7f7f2412cb 100644
--- a/graphics/pixelformat.h
+++ b/graphics/pixelformat.h
@@ -70,7 +70,7 @@ struct PixelFormat {
static inline PixelFormat createFormatCLUT8() {
return PixelFormat(1,8,8,8,8,0,0,0,0);
}
-#if (defined ENABLE_16BIT) || (defined ENABLE_32BIT) //TODO: more generic define instead of ENABLE_16BIT
+#ifdef ENABLE_RGB_COLOR
//2 Bytes-per-pixel modes
static inline PixelFormat createFormatRGB555() {
return PixelFormat(2,3,3,3,8,10,5,0,0);
@@ -94,7 +94,7 @@ struct PixelFormat {
return PixelFormat(4,0,0,0,0,24,16,8,0);
}
#endif //ENABLE_32BIT
-#endif //ENABLE_16BIT or ENABLE_32BIT
+#endif //ENABLE_RGB_COLOR
inline bool operator==(const PixelFormat &fmt) const {
// TODO: If aLoss==8, then the value of aShift is irrelevant, and should be ignored.