ggpo: move endOfFrame() call back to start render

Naomi2 TA context geometry for the current frame is lost when
rollbacking during vblank in because it hasn't been queued for render
yet.
Fixes black screen after GGPO rollback for Naomi 2 games
This commit is contained in:
Flyinghead 2023-02-03 11:34:58 +01:00
parent 90e9f70a1a
commit 6e940e4d08
3 changed files with 6 additions and 2 deletions

View File

@ -928,7 +928,9 @@ void Emulator::vblank()
if (sh4_sched_now64() - startTime <= 10000000)
return;
renderTimeout = true;
if (!ggpo::active() && !config::ThreadedRendering)
if (ggpo::active())
ggpo::endOfFrame();
else if (!config::ThreadedRendering)
sh4_cpu.Stop();
}

View File

@ -395,6 +395,9 @@ void rend_start_render()
ctx->rend.fog_clamp_min = FOG_CLAMP_MIN;
ctx->rend.fog_clamp_max = FOG_CLAMP_MAX;
if (!ctx->rend.isRTT)
ggpo::endOfFrame();
if (QueueRender(ctx))
{
palette_update();

View File

@ -113,7 +113,6 @@ static int spg_line_sched(int tag, int cycles, int jitter)
SB_MDST = 0;
}
asic_RaiseInterrupt(holly_SCANINT1);
ggpo::endOfFrame();
}
if (SPG_VBLANK_INT.vblank_out_interrupt_line_number == prv_cur_scanline)