GBA Video: Fix up last commit, add cinema tests

This commit is contained in:
Vicki Pfau 2019-01-20 01:00:49 -08:00
parent 88ba6ee0b0
commit bd8fe4d878
10 changed files with 3 additions and 7 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

View File

@ -151,9 +151,6 @@ int GBAVideoSoftwareRendererPreprocessSprite(struct GBAVideoSoftwareRenderer* re
if (GBARegisterDISPCNTGetMode(renderer->dispcnt) >= 3 && GBAObjAttributesCGetTile(sprite->c) < 512) { if (GBARegisterDISPCNTGetMode(renderer->dispcnt) >= 3 && GBAObjAttributesCGetTile(sprite->c) < 512) {
return 0; return 0;
} }
if (renderer->spriteCyclesRemaining <= 0) {
return 0;
}
int objwinSlowPath = GBARegisterDISPCNTIsObjwinEnable(renderer->dispcnt) && GBAWindowControlGetBlendEnable(renderer->objwin.packed) != GBAWindowControlIsBlendEnable(renderer->currentWindow.packed); int objwinSlowPath = GBARegisterDISPCNTIsObjwinEnable(renderer->dispcnt) && GBAWindowControlGetBlendEnable(renderer->objwin.packed) != GBAWindowControlIsBlendEnable(renderer->currentWindow.packed);
int variant = renderer->target1Obj && int variant = renderer->target1Obj &&

View File

@ -833,14 +833,13 @@ static void _drawScanline(struct GBAVideoSoftwareRenderer* renderer, int y) {
break; break;
} }
renderer->currentWindow = renderer->windows[w].control; renderer->currentWindow = renderer->windows[w].control;
renderer->start = renderer->end;
renderer->end = renderer->windows[w].endX;
if (!GBAWindowControlIsObjEnable(renderer->currentWindow.packed) && !GBARegisterDISPCNTIsObjwinEnable(renderer->dispcnt)) { if (!GBAWindowControlIsObjEnable(renderer->currentWindow.packed) && !GBARegisterDISPCNTIsObjwinEnable(renderer->dispcnt)) {
continue; continue;
} }
int drawn; int drawn = GBAVideoSoftwareRendererPreprocessSprite(renderer, &sprite->obj, localY);
renderer->start = renderer->end;
renderer->end = renderer->windows[w].endX;
drawn = GBAVideoSoftwareRendererPreprocessSprite(renderer, &sprite->obj, localY);
spriteLayers |= drawn << GBAObjAttributesCGetPriority(sprite->obj.c); spriteLayers |= drawn << GBAObjAttributesCGetPriority(sprite->obj.c);
} }
if (renderer->spriteCyclesRemaining <= 0) { if (renderer->spriteCyclesRemaining <= 0) {