mirror of https://github.com/mgba-emu/mgba.git
GBA Video: Blended sprites should never have other effects applied
This commit is contained in:
parent
57ac3e6529
commit
ec529a86c7
1
CHANGES
1
CHANGES
|
@ -23,6 +23,7 @@ Bugfixes:
|
||||||
- GBA Memory: Improve Thumb open bus behavior
|
- GBA Memory: Improve Thumb open bus behavior
|
||||||
- VFS: Fix resource leaks if some allocations fail
|
- VFS: Fix resource leaks if some allocations fail
|
||||||
- Video: Fix an issue with very long filenames
|
- Video: Fix an issue with very long filenames
|
||||||
|
- GBA Video: Blended sprites should never have other effects applied
|
||||||
Misc:
|
Misc:
|
||||||
- Qt: Handle saving input settings better
|
- Qt: Handle saving input settings better
|
||||||
- Debugger: Free watchpoints in addition to breakpoints
|
- Debugger: Free watchpoints in addition to breakpoints
|
||||||
|
|
|
@ -1764,8 +1764,7 @@ static int _preprocessSprite(struct GBAVideoSoftwareRenderer* renderer, struct G
|
||||||
uint16_t* vramBase = &renderer->d.vram[BASE_TILE >> 1];
|
uint16_t* vramBase = &renderer->d.vram[BASE_TILE >> 1];
|
||||||
unsigned charBase = GBAObjAttributesCGetTile(sprite->c) * 0x20;
|
unsigned charBase = GBAObjAttributesCGetTile(sprite->c) * 0x20;
|
||||||
int variant = renderer->target1Obj && GBAWindowControlIsBlendEnable(renderer->currentWindow.packed) && (renderer->blendEffect == BLEND_BRIGHTEN || renderer->blendEffect == BLEND_DARKEN);
|
int variant = renderer->target1Obj && GBAWindowControlIsBlendEnable(renderer->currentWindow.packed) && (renderer->blendEffect == BLEND_BRIGHTEN || renderer->blendEffect == BLEND_DARKEN);
|
||||||
if (GBAObjAttributesAGetMode(sprite->a) == OBJ_MODE_SEMITRANSPARENT && renderer->target2Bd) {
|
if (GBAObjAttributesAGetMode(sprite->a) == OBJ_MODE_SEMITRANSPARENT) {
|
||||||
// Hack: if a sprite is blended, then the variant palette is not used, but we don't know if it's blended in advance
|
|
||||||
variant = 0;
|
variant = 0;
|
||||||
}
|
}
|
||||||
color_t* palette = &renderer->normalPalette[0x100];
|
color_t* palette = &renderer->normalPalette[0x100];
|
||||||
|
|
Loading…
Reference in New Issue