diff options
author | Johannes Schickel | 2011-04-17 16:24:52 +0200 |
---|---|---|
committer | Johannes Schickel | 2011-04-17 16:24:52 +0200 |
commit | 39b993fb02749a2a1988f64d3443580f2e1c03ef (patch) | |
tree | 582ee5e5230d2445fe8e63ba3fdcce4320cced34 /graphics/thumbnail.cpp | |
parent | 7ac3ae108a69587693e0820cde43a63c34a186ec (diff) | |
download | scummvm-rg350-39b993fb02749a2a1988f64d3443580f2e1c03ef.tar.gz scummvm-rg350-39b993fb02749a2a1988f64d3443580f2e1c03ef.tar.bz2 scummvm-rg350-39b993fb02749a2a1988f64d3443580f2e1c03ef.zip |
GRAPHICS: Prefer Surface::create taking a PixelFormat over the one taking a byte depth.
Diffstat (limited to 'graphics/thumbnail.cpp')
-rw-r--r-- | graphics/thumbnail.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/graphics/thumbnail.cpp b/graphics/thumbnail.cpp index 8688096c3d..953faea484 100644 --- a/graphics/thumbnail.cpp +++ b/graphics/thumbnail.cpp @@ -107,10 +107,10 @@ bool loadThumbnail(Common::SeekableReadStream &in, Graphics::Surface &to) { return false; } - to.create(header.width, header.height, sizeof(OverlayColor)); + Graphics::PixelFormat format = g_system->getOverlayFormat(); + to.create(header.width, header.height, format); OverlayColor *pixels = (OverlayColor *)to.pixels; - Graphics::PixelFormat format = g_system->getOverlayFormat(); for (int y = 0; y < to.h; ++y) { for (int x = 0; x < to.w; ++x) { uint8 r, g, b; |