aboutsummaryrefslogtreecommitdiff
path: root/engines/sci/gfx/gfx_tools.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/sci/gfx/gfx_tools.cpp')
-rw-r--r--engines/sci/gfx/gfx_tools.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/engines/sci/gfx/gfx_tools.cpp b/engines/sci/gfx/gfx_tools.cpp
index e1378e14d0..4e570f5931 100644
--- a/engines/sci/gfx/gfx_tools.cpp
+++ b/engines/sci/gfx/gfx_tools.cpp
@@ -49,6 +49,7 @@ gfx_mode_t *gfx_new_mode(int xfact, int yfact, const Graphics::PixelFormat &form
mode->xfact = xfact;
mode->yfact = yfact;
mode->bytespp = format.bytesPerPixel;
+ mode->format = format;
// FIXME: I am not sure whether the following assignments are quite right.
// The only code using these are the built-in scalers of the SCI engine.
@@ -60,10 +61,10 @@ gfx_mode_t *gfx_new_mode(int xfact, int yfact, const Graphics::PixelFormat &form
mode->green_mask = format.ARGBToColor(0, 0, 0xFF, 0);
mode->blue_mask = format.ARGBToColor(0, 0, 0, 0xFF);
mode->alpha_mask = format.ARGBToColor(0xFF, 0, 0, 0);
- mode->red_shift = format.rLoss;
- mode->green_shift = format.gLoss;
- mode->blue_shift = format.bLoss;
- mode->alpha_shift = format.aLoss;
+ mode->red_shift = format.rShift;
+ mode->green_shift = format.gShift;
+ mode->blue_shift = format.bShift;
+ mode->alpha_shift = format.aShift;
} else {
mode->red_mask = mode->green_mask = mode->blue_mask = 0;
mode->alpha_mask = 0;