diff options
Diffstat (limited to 'engines/bladerunner/shape.cpp')
-rw-r--r-- | engines/bladerunner/shape.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/engines/bladerunner/shape.cpp b/engines/bladerunner/shape.cpp index de7a572fa6..60fa869fc1 100644 --- a/engines/bladerunner/shape.cpp +++ b/engines/bladerunner/shape.cpp @@ -112,11 +112,11 @@ void Shape::draw(Graphics::Surface &surface, int x, int y) const { uint8 a, r, g, b; gameDataPixelFormat().colorToARGB(shpColor, a, r, g, b); - // Ignore the alpha in the output as it is inversed in the input - uint16 outColor = (uint16)surface.format.RGBToColor(r, g, b); if (!a) { - *(uint16 *)(surface.getBasePtr(CLIP(dst_x + xi, 0, surface.w - 1), CLIP(dst_y + yi, 0, surface.h - 1))) = outColor; + // Ignore the alpha in the output as it is inversed in the input + void *dstPtr = surface.getBasePtr(CLIP(dst_x + xi, 0, surface.w - 1), CLIP(dst_y + yi, 0, surface.h - 1)); + drawPixel(surface, dstPtr, surface.format.RGBToColor(r, g, b)); } } src_p += 2 * (_width - rect_w); |