diff options
author | Arisotura <thetotalworm@gmail.com> | 2019-06-01 03:39:35 +0200 |
---|---|---|
committer | Arisotura <thetotalworm@gmail.com> | 2019-06-01 03:39:35 +0200 |
commit | 78208a9728bab7b381c8eac570ff42a1936161ba (patch) | |
tree | 58860726d27fac3c63b5caa53924eb2c9ef1e954 /src | |
parent | 27d21e06df8d24ab6c4e53ba5305af533b09f6f2 (diff) |
OpenGL: fix cases of layers/sprites blending over the 3D layer
Diffstat (limited to 'src')
-rw-r--r-- | src/GPU2D.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/GPU2D.cpp b/src/GPU2D.cpp index 4fe2209..212372c 100644 --- a/src/GPU2D.cpp +++ b/src/GPU2D.cpp @@ -1443,7 +1443,8 @@ void GPU2D::DrawScanline_BGOBJ(u32 line) eva = flag1 & 0x1F; evb = 16 - eva; } - else if ((BlendCnt & target1) && (WindowMask[i] & 0x20)) + else if (((BlendCnt & target1) && (WindowMask[i] & 0x20)) || + ((flag1 & 0xC0) == 0x80)) { eva = EVA; evb = EVB; @@ -1453,7 +1454,7 @@ void GPU2D::DrawScanline_BGOBJ(u32 line) BGOBJLine[i] = val1; BGOBJLine[256+i] = ColorComposite(i, val1, val3); - BGOBJLine[512+i] = (bldcnteffect << 24) | (EVB << 16) | (EVA << 8) | (val1 & 0xFF); + BGOBJLine[512+i] = (bldcnteffect << 24) | (EVB << 16) | (EVA << 8) | (val2 & 0xFF); } else { |