summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
3ab21f5)
* gte: backport fix for RTPS/RTPT
Fix glitched drawing of road surface in 'Burning Road'..
behavior now matches Mednafen. This also preserves the fix by Shalma
from prior commit
f916013 for missing elements in 'Legacy of Kain:
Soul Reaver' (missing green plasma balls in first level).
- backported fix from pcsx4all
https://github.com/dmitrysmagin/pcsx4all/pull/41/commits/
a6ff7d29d615bdb26b491f4e1e2a9f4608a8d643
- fixes R4 - Ridge Racer Type 4 lighting issue
* gte: change return to s64 for BOUNDS_
fix https://github.com/notaz/pcsx_rearmed/issues/129
-static inline s32 BOUNDS_(psxCP2Regs *regs, s64 n_value, s64 n_max, int n_maxflag, s64 n_min, int n_minflag) {
+static inline s64 BOUNDS_(psxCP2Regs *regs, s64 n_value, s64 n_max, int n_maxflag, s64 n_min, int n_minflag) {
if (n_value > n_max) {
gteFLAG |= n_maxflag;
} else if (n_value < n_min) {
if (n_value > n_max) {
gteFLAG |= n_maxflag;
} else if (n_value < n_min) {
void gteRTPS(psxCP2Regs *regs) {
int quotient;
void gteRTPS(psxCP2Regs *regs) {
int quotient;
#ifdef GTE_LOG
GTE_LOG("GTE RTPS\n");
#ifdef GTE_LOG
GTE_LOG("GTE RTPS\n");
gteSX2 = limG1(F((s64)gteOFX + ((s64)gteIR1 * quotient)) >> 16);
gteSY2 = limG2(F((s64)gteOFY + ((s64)gteIR2 * quotient)) >> 16);
gteSX2 = limG1(F((s64)gteOFX + ((s64)gteIR1 * quotient)) >> 16);
gteSY2 = limG2(F((s64)gteOFY + ((s64)gteIR2 * quotient)) >> 16);
- gteMAC0 = F((s64)gteDQB + ((s64)gteDQA * quotient));
- gteIR0 = limH(gteMAC0 >> 12);
+ tmp = (s64)gteDQB + ((s64)gteDQA * quotient);
+ gteMAC0 = F(tmp);
+ gteIR0 = limH(tmp >> 12);
}
void gteRTPT(psxCP2Regs *regs) {
int quotient;
int v;
s32 vx, vy, vz;
}
void gteRTPT(psxCP2Regs *regs) {
int quotient;
int v;
s32 vx, vy, vz;
#ifdef GTE_LOG
GTE_LOG("GTE RTPT\n");
#ifdef GTE_LOG
GTE_LOG("GTE RTPT\n");
fSX(v) = limG1(F((s64)gteOFX + ((s64)gteIR1 * quotient)) >> 16);
fSY(v) = limG2(F((s64)gteOFY + ((s64)gteIR2 * quotient)) >> 16);
}
fSX(v) = limG1(F((s64)gteOFX + ((s64)gteIR1 * quotient)) >> 16);
fSY(v) = limG2(F((s64)gteOFY + ((s64)gteIR2 * quotient)) >> 16);
}
- gteMAC0 = F((s64)gteDQB + ((s64)gteDQA * quotient));
- gteIR0 = limH(gteMAC0 >> 12);
+
+ tmp = (s64)gteDQB + ((s64)gteDQA * quotient);
+ gteMAC0 = F(tmp);
+ gteIR0 = limH(tmp >> 12);
}
void gteMVMVA(psxCP2Regs *regs) {
}
void gteMVMVA(psxCP2Regs *regs) {