From ca61b53f6c99e49de4620395bc8dbe5b71c9e2db Mon Sep 17 00:00:00 2001 From: iCatButler Date: Fri, 6 May 2016 17:12:31 +0100 Subject: More fixes for persective correct build - Switch back to fixed point GTE - Only clamp w to h/2 after divide - Fix vertex function for multi-pass (was overwriting vertexon first pass) --- libpcsxcore/gte.c | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) (limited to 'libpcsxcore/gte.c') diff --git a/libpcsxcore/gte.c b/libpcsxcore/gte.c index abe3c205..2938d170 100755 --- a/libpcsxcore/gte.c +++ b/libpcsxcore/gte.c @@ -497,11 +497,11 @@ int docop2(int op) { SX2 = Lm_G1(F((s64) OFX + ((s64) IR1 * h_over_sz3) * (Config.Widescreen ? 0.75 : 1)) >> 16); SY2 = Lm_G2(F((s64) OFY + ((s64) IR2 * h_over_sz3)) >> 16); - //PGXP_pushSXYZ2s(Lm_G1_ia((s64)OFX + (s64)(IR1 * h_over_sz3) * (Config.Widescreen ? 0.75 : 1)), - // Lm_G2_ia((s64)OFY + (s64)(IR2 * h_over_sz3)), - // SZ3, SXY2); + PGXP_pushSXYZ2s(Lm_G1_ia((s64)OFX + (s64)(IR1 * h_over_sz3) * (Config.Widescreen ? 0.75 : 1)), + Lm_G2_ia((s64)OFY + (s64)(IR2 * h_over_sz3)), + max(SZ3, H/2), SXY2); - PGXP_RTPS(0, SXY2); + //PGXP_RTPS(0, SXY2); MAC0 = F((s64) DQB + ((s64) DQA * h_over_sz3)); IR0 = Lm_H(m_mac0, 1); @@ -888,12 +888,19 @@ int docop2(int op) { SXY1 = SXY2; SX2 = Lm_G1(F((s64) OFX + ((s64) IR1 * h_over_sz3) * (Config.Widescreen ? 0.75 : 1)) >> 16); SY2 = Lm_G2(F((s64) OFY + ((s64) IR2 * h_over_sz3)) >> 16); - - //PGXP_pushSXYZ2s(Lm_G1_ia((s64)OFX + (s64)(IR1 * h_over_sz3) * (Config.Widescreen ? 0.75 : 1)), - // Lm_G2_ia((s64)OFY + (s64)(IR2 * h_over_sz3)), - // SZ3, SXY2); - PGXP_RTPS(v, SXY2); + //float tempMx = MAC1; + //float tempx = IR1; + //float temphow = (float)h_over_sz3 / (float)(1 << 16); + + //float tempMz = MAC3; + //float tempZ = SZ3; + // + PGXP_pushSXYZ2s(Lm_G1_ia((s64)OFX + (s64)(IR1 * h_over_sz3) * (Config.Widescreen ? 0.75 : 1)), + Lm_G2_ia((s64)OFY + (s64)(IR2 * h_over_sz3)), + max(SZ3, H/2), SXY2); + + //PGXP_RTPS(v, SXY2); } MAC0 = F((s64) DQB + ((s64) DQA * h_over_sz3)); -- cgit v1.2.3