From f2926412fe7966bc34ceea1f87f2a4dae51df2eb Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Mon, 14 Dec 2015 02:14:13 +0100 Subject: GRAPHICS: Fix fast ALPHA_BINARY blitting with TransparentSurface. This is a regression from 5d0f38d747e7583d0ca5959cd642468ba67cd04c and caused color glitches in Wintermute. --- graphics/transparent_surface.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'graphics') diff --git a/graphics/transparent_surface.cpp b/graphics/transparent_surface.cpp index 992a5dc879..19e7655a93 100644 --- a/graphics/transparent_surface.cpp +++ b/graphics/transparent_surface.cpp @@ -116,7 +116,7 @@ void doBlitBinaryFast(byte *ino, byte *outo, uint32 width, uint32 height, uint32 in = ino; for (uint32 j = 0; j < width; j++) { uint32 pix = *(uint32 *)in; - int a = (pix >> kAModShift) & 0xff; + int a = in[kAIndex]; if (a != 0) { // Full opacity (Any value not exactly 0 is Opaque here) *(uint32 *)out = pix; -- cgit v1.2.3