Move SSAO gInvProj to the CPU instead of GPU

Also make Mat4f.invert() return void instead of boolean to prevent confusion about trying to pass the result into shader uniforms.
This commit is contained in:
James Seibel
2023-08-31 21:06:41 -05:00
parent 751eb75c50
commit 08f78c22f0
3 changed files with 16 additions and 7 deletions
@@ -287,17 +287,18 @@ public class Mat4f
this.m23 = f;
}
public boolean invert()
public boolean canInvert()
{
float det = this.adjudicateAndDet();
return (Math.abs(det) > 1.0E-6F);
}
public void invert()
{
float det = this.adjudicateAndDet();
if (Math.abs(det) > 1.0E-6F)
{
this.multiply(det);
return true;
}
else
{
return false;
}
}