diff options
author | truelight <truelight@openttd.org> | 2007-06-20 10:26:39 +0000 |
---|---|---|
committer | truelight <truelight@openttd.org> | 2007-06-20 10:26:39 +0000 |
commit | d7acd238ac20d63f1ac4116152330b652d5c79d8 (patch) | |
tree | 679b899b117ebed068440e90c22be5b9457a20f0 /src/blitter | |
parent | 436eb69a3986fcb1e610ace7c8ee6e6115a37a6e (diff) | |
download | openttd-d7acd238ac20d63f1ac4116152330b652d5c79d8.tar.xz |
(svn r10233) -Fix: 8bpp-optimized encoder fucked up if 255+ pixels in a row were non-transparent (tnx boekabart)
Diffstat (limited to 'src/blitter')
-rw-r--r-- | src/blitter/8bpp_optimized.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/blitter/8bpp_optimized.cpp b/src/blitter/8bpp_optimized.cpp index 9af922e30..2548fc6be 100644 --- a/src/blitter/8bpp_optimized.cpp +++ b/src/blitter/8bpp_optimized.cpp @@ -151,7 +151,7 @@ Sprite *Blitter_8bppOptimized::Encode(SpriteLoader::Sprite *sprite, Blitter::All if (rx == sprite->width) break; } - if (last_color == 0 || color == 0) { + if (last_color == 0 || color == 0 || pixels > 250) { if (count_index != 0) { /* Write how many non-transparent bytes we get */ temp_dst[count_index] = pixels; |