Fix mixing colors on 16-bit
Jeffrey Pfau jeffrey@endrift.com
Tue, 05 Nov 2013 04:13:49 -0800
1 files changed,
2 insertions(+),
2 deletions(-)
M
src/gba/renderers/video-software.c
→
src/gba/renderers/video-software.c
@@ -1484,14 +1484,14 @@ a = colorA & 0x3E0;
b = colorB & 0x3E0; c |= ((a * weightA + b * weightB) / 16) & 0x7E0; if (c & 0x0400) { - c |= 0x03E0; + c = (c & 0x001F) | 0x03E0; } a = colorA & 0x7C00; b = colorB & 0x7C00; c |= ((a * weightA + b * weightB) / 16) & 0xFC00; if (c & 0x8000) { - c |= 0x7C00; + c = (c &0x03FF) | 0x7C00; } #else a = colorA & 0xF8;