diff options
author | Marcus Comstedt | 2005-04-03 20:48:23 +0000 |
---|---|---|
committer | Marcus Comstedt | 2005-04-03 20:48:23 +0000 |
commit | c31f685e4441c773b909189a9cfaf226e89f95a0 (patch) | |
tree | c7ec56d03f74f2bc492871c0a45b58b0ba68e985 | |
parent | 4187ed3e113736c88fea726a57aaf14612499408 (diff) | |
download | scummvm-rg350-c31f685e4441c773b909189a9cfaf226e89f95a0.tar.gz scummvm-rg350-c31f685e4441c773b909189a9cfaf226e89f95a0.tar.bz2 scummvm-rg350-c31f685e4441c773b909189a9cfaf226e89f95a0.zip |
Added ARGB4444 case to table generation.
Maybe this should really be a single case using RGBToColor instead...
svn-id: r17357
-rw-r--r-- | graphics/animation.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/graphics/animation.cpp b/graphics/animation.cpp index 3ba6179ffd..9f57f5a650 100644 --- a/graphics/animation.cpp +++ b/graphics/animation.cpp @@ -418,6 +418,18 @@ void BaseAnimationState::buildLookup() { b_2_pix_alloc[i + 256] = i >> (8 - 5); // b_2_pix_alloc[i + 256] <<= 0; } + } else if (gBitFormat == 4444) { + for (i = 0; i < 256; i++) { + r_2_pix_alloc[i + 256] = i >> (8 - 4); + r_2_pix_alloc[i + 256] <<= 8; + g_2_pix_alloc[i + 256] = i >> (8 - 4); + g_2_pix_alloc[i + 256] <<= 4; + b_2_pix_alloc[i + 256] = i >> (8 - 4); + // b_2_pix_alloc[i + 256] <<= 0; + r_2_pix_alloc[i + 256] |= 0xf000; + g_2_pix_alloc[i + 256] |= 0xf000; + b_2_pix_alloc[i + 256] |= 0xf000; + } } else { error("Unknown bit format %d", gBitFormat); } |