mirror of
https://github.com/HarbourMasters/SpaghettiKart
synced 2026-06-19 07:57:00 -04:00
Fix screen blanking (#627)
* Update main.c * Update skybox_and_splitscreen.c * Adjust framebuffer handling in race_logic_loop Reorder framebuffer clearing and creation for proper rendering.
This commit is contained in:
+3
-2
@@ -469,7 +469,7 @@ void* clear_framebuffer(s32 color) {
|
||||
gDPSetCycleType(gDisplayListHead++, G_CYC_FILL);
|
||||
|
||||
gDPSetFillColor(gDisplayListHead++, color);
|
||||
gDPFillRectangle(gDisplayListHead++, 0, 0, SCREEN_WIDTH - 1, SCREEN_HEIGHT - 1);
|
||||
gDPFillWideRectangle(gDisplayListHead++, OTRGetRectDimensionFromLeftEdge(0), 0, OTRGetGameRenderWidth(), SCREEN_HEIGHT);
|
||||
|
||||
gDPPipeSync(gDisplayListHead++);
|
||||
|
||||
@@ -1172,8 +1172,9 @@ void thread5_iteration(void) {
|
||||
}
|
||||
profiler_log_thread5_time(THREAD5_START);
|
||||
config_gfx_pool();
|
||||
FB_CreateFramebuffers();
|
||||
read_controllers();
|
||||
FB_CreateFramebuffers();
|
||||
clear_framebuffer(0); // Clear the framebuffer
|
||||
game_state_handler();
|
||||
|
||||
// call_render_hook();
|
||||
|
||||
@@ -280,7 +280,7 @@ void select_framebuffer(void) {
|
||||
GPACK_RGBA5551(D_800DC5D0, D_800DC5D4, D_800DC5D8, 1));
|
||||
gDPPipeSync(gDisplayListHead++);
|
||||
gDPSetScissor(gDisplayListHead++, G_SC_NON_INTERLACE, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT);
|
||||
gDPFillRectangle(gDisplayListHead++, 0, 0, SCREEN_WIDTH - 1, SCREEN_HEIGHT - 1);
|
||||
gDPFillWideRectangle(gDisplayListHead++, OTRGetRectDimensionFromLeftEdge(0), 0, OTRGetGameRenderWidth(), SCREEN_HEIGHT);
|
||||
gDPPipeSync(gDisplayListHead++);
|
||||
gDPSetCycleType(gDisplayListHead++, G_CYC_1CYCLE);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user