GBA Video: Fix sprite priority regression (fixes #1419)
After Width: | Height: | Size: 29 KiB |
After Width: | Height: | Size: 29 KiB |
After Width: | Height: | Size: 29 KiB |
After Width: | Height: | Size: 29 KiB |
After Width: | Height: | Size: 29 KiB |
After Width: | Height: | Size: 29 KiB |
After Width: | Height: | Size: 29 KiB |
|
@ -80,7 +80,7 @@
|
|||
LOAD_16(tileData, ((yBase + charBase + xBase) & 0x7FFE), vramBase); \
|
||||
tileData = (tileData >> ((localX & 3) << 2)) & 0xF; \
|
||||
current = renderer->spriteLayer[outX]; \
|
||||
if ((current & FLAG_UNWRITTEN) == FLAG_UNWRITTEN && tileData) { \
|
||||
if ((current & FLAG_ORDER_MASK) > flags && tileData) { \
|
||||
renderer->spriteLayer[outX] = palette[tileData] | flags; \
|
||||
}
|
||||
|
||||
|
@ -88,7 +88,7 @@
|
|||
LOAD_16(tileData, ((yBase + charBase + xBase) & 0x7FFE), vramBase); \
|
||||
tileData = (tileData >> ((localX & 3) << 2)) & 0xF; \
|
||||
current = renderer->spriteLayer[outX]; \
|
||||
if ((current & FLAG_UNWRITTEN) == FLAG_UNWRITTEN && tileData) { \
|
||||
if ((current & FLAG_ORDER_MASK) > flags && tileData) { \
|
||||
unsigned color = (renderer->row[outX] & FLAG_OBJWIN) ? objwinPalette[tileData] : palette[tileData]; \
|
||||
renderer->spriteLayer[outX] = color | flags; \
|
||||
}
|
||||
|
@ -107,7 +107,7 @@
|
|||
LOAD_16(tileData, ((yBase + charBase + xBase) & 0x7FFE), vramBase); \
|
||||
tileData = (tileData >> ((localX & 1) << 3)) & 0xFF; \
|
||||
current = renderer->spriteLayer[outX]; \
|
||||
if ((current & FLAG_UNWRITTEN) == FLAG_UNWRITTEN && tileData) { \
|
||||
if ((current & FLAG_ORDER_MASK) > flags && tileData) { \
|
||||
renderer->spriteLayer[outX] = palette[tileData] | flags; \
|
||||
}
|
||||
|
||||
|
@ -115,7 +115,7 @@
|
|||
LOAD_16(tileData, ((yBase + charBase + xBase) & 0x7FFE), vramBase); \
|
||||
tileData = (tileData >> ((localX & 1) << 3)) & 0xFF; \
|
||||
current = renderer->spriteLayer[outX]; \
|
||||
if ((current & FLAG_UNWRITTEN) == FLAG_UNWRITTEN && tileData) { \
|
||||
if ((current & FLAG_ORDER_MASK) > flags && tileData) { \
|
||||
unsigned color = (renderer->row[outX] & FLAG_OBJWIN) ? objwinPalette[tileData] : palette[tileData]; \
|
||||
renderer->spriteLayer[outX] = color | flags; \
|
||||
}
|
||||
|
|