mirror of https://github.com/PCSX2/pcsx2.git
GS: Fixes for flushes from PR #6389
This commit is contained in:
parent
1910c8fc0f
commit
9750cfe6bf
|
@ -802,7 +802,7 @@ void GSState::GIFPackedRegHandlerXYZF2(const GIFPackedReg* RESTRICT r)
|
||||||
|
|
||||||
m_v.m[1] = xy.upl32(zf);
|
m_v.m[1] = xy.upl32(zf);
|
||||||
|
|
||||||
VertexKick<prim, auto_flush, index_swap>(adc ? 1 : r->XYZ2.Skip());
|
VertexKick<prim, auto_flush, index_swap>(adc ? 1 : r->XYZF2.Skip());
|
||||||
}
|
}
|
||||||
|
|
||||||
template <u32 prim, u32 adc, bool auto_flush, bool index_swap>
|
template <u32 prim, u32 adc, bool auto_flush, bool index_swap>
|
||||||
|
@ -1945,17 +1945,19 @@ void GSState::Write(const u8* mem, int len)
|
||||||
if (!m_tr.Update(w, h, psm.trbpp, len))
|
if (!m_tr.Update(w, h, psm.trbpp, len))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
// TODO: Not really sufficient if a partial texture update is done outside the block.
|
||||||
|
// No need to check CLUT here, we can invalidate it below, no need to flush it since TEX0 needs to update, then we can flush.
|
||||||
|
// Only flush on a NEW transfer if a pending one is using the same address.
|
||||||
|
// Check Fast & Furious (Hardare mode) and Assault Suits Valken (either renderer).
|
||||||
|
if (m_tr.end == 0 && m_index.tail > 0 && m_prev_env.PRIM.TME &&
|
||||||
|
(blit.DBP == m_prev_env.CTXT[m_prev_env.PRIM.CTXT].TEX0.TBP0 || blit.DBP == m_prev_env.CTXT[m_prev_env.PRIM.CTXT].TEX0.CBP))
|
||||||
|
Flush();
|
||||||
|
|
||||||
GL_CACHE("Write! ... => 0x%x W:%d F:%s (DIR %d%d), dPos(%d %d) size(%d %d)",
|
GL_CACHE("Write! ... => 0x%x W:%d F:%s (DIR %d%d), dPos(%d %d) size(%d %d)",
|
||||||
blit.DBP, blit.DBW, psm_str(blit.DPSM),
|
blit.DBP, blit.DBW, psm_str(blit.DPSM),
|
||||||
m_env.TRXPOS.DIRX, m_env.TRXPOS.DIRY,
|
m_env.TRXPOS.DIRX, m_env.TRXPOS.DIRY,
|
||||||
m_env.TRXPOS.DSAX, m_env.TRXPOS.DSAY, w, h);
|
m_env.TRXPOS.DSAX, m_env.TRXPOS.DSAY, w, h);
|
||||||
|
|
||||||
// TODO: Not really sufficient if a partial texture update is done outside the block.
|
|
||||||
// No need to check CLUT here, we can invalidate it below, no need to flush it since TEX0 needs to update, then we can flush.
|
|
||||||
if ((PRIM->TME && (blit.DBP == m_context->TEX0.TBP0)) ||
|
|
||||||
(m_prev_env.PRIM.TME && (blit.DBP == m_prev_env.CTXT[m_prev_env.PRIM.CTXT].TEX0.TBP0)))
|
|
||||||
Flush();
|
|
||||||
|
|
||||||
if (m_tr.end == 0 && len >= m_tr.total)
|
if (m_tr.end == 0 && len >= m_tr.total)
|
||||||
{
|
{
|
||||||
// received all data in one piece, no need to buffer it
|
// received all data in one piece, no need to buffer it
|
||||||
|
|
Loading…
Reference in New Issue