diff options
author | Max Horn | 2004-02-22 21:01:40 +0000 |
---|---|---|
committer | Max Horn | 2004-02-22 21:01:40 +0000 |
commit | cfd248eeb971dc1205bac66f28745a06184accf4 (patch) | |
tree | a608bd87a813143ba5537f578a52aaa19aa8b843 | |
parent | e469cd43a741e2f6d94419f1b3e12039dcdfc7ce (diff) | |
download | scummvm-rg350-cfd248eeb971dc1205bac66f28745a06184accf4.tar.gz scummvm-rg350-cfd248eeb971dc1205bac66f28745a06184accf4.tar.bz2 scummvm-rg350-cfd248eeb971dc1205bac66f28745a06184accf4.zip |
avoid #include scaler.h
svn-id: r12997
-rw-r--r-- | base/gameDetector.cpp | 32 | ||||
-rw-r--r-- | base/gameDetector.h | 32 | ||||
-rw-r--r-- | gui/options.cpp | 4 |
3 files changed, 34 insertions, 34 deletions
diff --git a/base/gameDetector.cpp b/base/gameDetector.cpp index c2b31c3bb2..d5cb1eaef2 100644 --- a/base/gameDetector.cpp +++ b/base/gameDetector.cpp @@ -96,6 +96,36 @@ static const char USAGE_STRING[] = ; #endif +/** + * List of graphic 'modes' we potentially support. Potentially because not all + * backends actually support all the filters listed here. At this point only + * the SDL backend supports all (except for the PalmOS ones of course). + * @todo Remove this explicit list of graphic modes and rather extend the + * OSystem API to allow querying a backend for the modes it supports. + */ +const GraphicsMode g_gfx_modes[] = { + {"normal", "Normal (no scaling)", GFX_NORMAL}, + {"1x", "Normal (no scaling)", GFX_NORMAL}, +#ifndef __PALM_OS__ // reduce contant data size + {"2x", "2x", GFX_DOUBLESIZE}, + {"3x", "3x", GFX_TRIPLESIZE}, + {"2xsai", "2xSAI", GFX_2XSAI}, + {"super2xsai", "Super2xSAI", GFX_SUPER2XSAI}, + {"supereagle", "SuperEagle", GFX_SUPEREAGLE}, + {"advmame2x", "AdvMAME2x", GFX_ADVMAME2X}, + {"advmame3x", "AdvMAME3x", GFX_ADVMAME3X}, + {"hq2x", "HQ2x", GFX_HQ2X}, + {"hq3x", "HQ3x", GFX_HQ3X}, + {"tv2x", "TV2x", GFX_TV2X}, + {"dotmatrix", "DotMatrix", GFX_DOTMATRIX}, +#else + {"flipping", "Page Flipping", GFX_FLIPPING}, + {"buffered", "Buffered", GFX_BUFFERED}, + {"wide", "Wide (HiRes+ only)", GFX_WIDE}, +#endif + {0, 0, 0} +}; + GameDetector::GameDetector() { // Graphics @@ -468,7 +498,7 @@ int GameDetector::parseGraphicsMode(const String &str) { return -1; const char *s = str.c_str(); - const GraphicsMode *gm = gfx_modes; + const GraphicsMode *gm = g_gfx_modes; while (gm->name) { if (!scumm_stricmp(gm->name, s)) { return gm->id; diff --git a/base/gameDetector.h b/base/gameDetector.h index c5a7afedb9..62fc365055 100644 --- a/base/gameDetector.h +++ b/base/gameDetector.h @@ -24,7 +24,6 @@ #define GAMEDETECTOR_H #include "common/str.h" -#include "common/scaler.h" class Engine; class GameDetector; @@ -61,36 +60,7 @@ struct GraphicsMode { int id; }; -/** - * List of graphic 'modes' we potentially support. Potentially because not all - * backends actually support all the filters listed here. At this point only - * the SDL backend supports all (except for the PalmOS ones of course). - * @todo Remove this explicit list of graphic modes and rather extend the - * OSystem API to allow querying a backend for the modes it supports. - */ -static const struct GraphicsMode gfx_modes[] = { - {"normal", "Normal (no scaling)", GFX_NORMAL}, - {"1x", "Normal (no scaling)", GFX_NORMAL}, -#ifndef __PALM_OS__ // reduce contant data size - {"2x", "2x", GFX_DOUBLESIZE}, - {"3x", "3x", GFX_TRIPLESIZE}, - {"2xsai", "2xSAI", GFX_2XSAI}, - {"super2xsai", "Super2xSAI", GFX_SUPER2XSAI}, - {"supereagle", "SuperEagle", GFX_SUPEREAGLE}, - {"advmame2x", "AdvMAME2x", GFX_ADVMAME2X}, - {"advmame3x", "AdvMAME3x", GFX_ADVMAME3X}, - {"hq2x", "HQ2x", GFX_HQ2X}, - {"hq3x", "HQ3x", GFX_HQ3X}, - {"tv2x", "TV2x", GFX_TV2X}, - {"dotmatrix", "DotMatrix", GFX_DOTMATRIX}, -#else - {"flipping", "Page Flipping", GFX_FLIPPING}, - {"buffered", "Buffered", GFX_BUFFERED}, - {"wide", "Wide (HiRes+ only)", GFX_WIDE}, -#endif - {0, 0, 0} -}; - +extern const GraphicsMode g_gfx_modes[]; class GameDetector { typedef Common::String String; diff --git a/gui/options.cpp b/gui/options.cpp index 06a93438c7..b4b35f1d41 100644 --- a/gui/options.cpp +++ b/gui/options.cpp @@ -77,7 +77,7 @@ void OptionsDialog::open() { _gfxPopUp->setEnabled(false); if (ConfMan.hasKey("gfx_mode", _domain)) { - const GraphicsMode *gm = gfx_modes; + const GraphicsMode *gm = g_gfx_modes; String gfxMode = ConfMan.get("gfx_mode", _domain); int gfxCount = 1; while (gm->name) { @@ -255,7 +255,7 @@ void OptionsDialog::setVolumeSettingsState(bool enabled) { int OptionsDialog::addGraphicControls(GuiObject *boss, int yoffset) { const int x = 10; const int w = _w - 2 * 10; - const GraphicsMode *gm = gfx_modes; + const GraphicsMode *gm = g_gfx_modes; // The GFX mode popup _gfxPopUp = new PopUpWidget(boss, x-5, yoffset, w+5, kLineHeight, "Graphics mode: ", 100); |