Fix compatibility mode singularity shader (#7856)

This commit is contained in:
Leon Friedrich
2022-04-30 01:45:05 +12:00
committed by GitHub
parent 6d8f06e583
commit 79204b0052

View File

@@ -3,7 +3,7 @@
uniform sampler2D SCREEN_TEXTURE;
uniform highp vec2 renderScale;
uniform highp float maxDistance;
uniform int count;
uniform lowp int count;
uniform highp float[5] falloffPower;
uniform highp float[5] intensity;
@@ -30,9 +30,9 @@ void fragment() {
// avoids long-range single-pixel shifts that are noticeable when leaving PVS.
if (distance >= maxDistance) {
deformation = 0;
deformation = 0.0;
} else {
deformation *= (1 - pow(distance/maxDistance, 4));
deformation *= (1.0 - pow(distance/maxDistance, 4.0));
}
if(deformation > 0.8)