mirror of https://github.com/PCSX2/pcsx2.git
[Soft-Float] - Fixes Tony Hawk Pro Skater 4 Mul issue.
The game sends some super low floats to the Mul unit. On PS2, floats with exponent zero should return zero, but this is not the case in Mul, the multiplier can work with denormals internally. I love when undocumented stuff is used by some games for their 3D engine ^^.
This commit is contained in:
parent
de047eaa40
commit
b7f38061df
|
@ -399,7 +399,7 @@ Ps2Float Ps2Float::DoMul(Ps2Float other)
|
|||
|
||||
if (resExponent > 255)
|
||||
return result.Sign ? Min() : Max();
|
||||
else if (resExponent <= 0)
|
||||
else if (resExponent < 0)
|
||||
return Ps2Float(result.Sign, 0, 0);
|
||||
|
||||
uint32_t testImprecision = otherMantissa ^ ((otherMantissa >> 4) & 0x800); // For some reason, 0x808000 loses a bit and 0x800800 loses a bit, but 0x808800 does not
|
||||
|
|
Loading…
Reference in New Issue