diff options
author | Max Horn | 2002-12-25 23:18:30 +0000 |
---|---|---|
committer | Max Horn | 2002-12-25 23:18:30 +0000 |
commit | 91fc86eede6e9e1ffc5f3f01e47b17bbbc2fb98d (patch) | |
tree | 42564f04e33a42f2ded7d8eac220aafe9be2cb37 /scumm | |
parent | a782a22c4dce266aa53bba74e68483f4e48412d0 (diff) | |
download | scummvm-rg350-91fc86eede6e9e1ffc5f3f01e47b17bbbc2fb98d.tar.gz scummvm-rg350-91fc86eede6e9e1ffc5f3f01e47b17bbbc2fb98d.tar.bz2 scummvm-rg350-91fc86eede6e9e1ffc5f3f01e47b17bbbc2fb98d.zip |
cleanup
svn-id: r6153
Diffstat (limited to 'scumm')
-rw-r--r-- | scumm/nut_renderer.cpp | 11 | ||||
-rw-r--r-- | scumm/scummvm.cpp | 10 |
2 files changed, 7 insertions, 14 deletions
diff --git a/scumm/nut_renderer.cpp b/scumm/nut_renderer.cpp index 0cb1c1f41f..1d5ea3d99c 100644 --- a/scumm/nut_renderer.cpp +++ b/scumm/nut_renderer.cpp @@ -223,14 +223,8 @@ void NutRenderer::drawChar(char c, int32 x, int32 y, byte color) { for (int32 tx = 0; tx < width; tx++) { byte pixel = *(_tmpCodecBuffer + ty * width + tx); if (pixel != 0) { - if (color == 0) { - if (pixel == 0x01) - pixel = 0xf; - } - else { - if (pixel == 0x01) - pixel = color; - } + if (pixel == 0x01) + pixel = (color == 0) ? 0xf : color; if (pixel == 0xff) pixel = 0x0; *(_dstPtr + ((ty + y) * _dstPitch + x + tx)) = pixel; @@ -238,4 +232,3 @@ void NutRenderer::drawChar(char c, int32 x, int32 y, byte color) { } } } - diff --git a/scumm/scummvm.cpp b/scumm/scummvm.cpp index f2daa8af4d..1e9efbbd5b 100644 --- a/scumm/scummvm.cpp +++ b/scumm/scummvm.cpp @@ -207,6 +207,11 @@ void Scumm::scummInit() else _resourceHeaderSize = 8; + if (_features & GF_OLD256) + _charset = new CharsetRendererOld256(this); + else + _charset = new CharsetRendererClassic(this); + memset(_charsetData, 0, sizeof(_charsetData)); if (!(_features & GF_SMALL_NAMES) && !(_features & GF_AFTER_V8)) @@ -1552,11 +1557,6 @@ void Scumm::mainRun() void Scumm::launch() { - if (_features & GF_OLD256) - _charset = new CharsetRendererOld256(this); - else - _charset = new CharsetRendererClassic(this); - gdi._vm = this; _maxHeapThreshold = 450000; |