Revert a hack for shadows.

It helps for horizontal surfaces, but makes vertical surfaces worse (for example rocks in cornfield crossing), so it's not really a solution.
This commit is contained in:
Deve 2017-10-04 22:18:32 +02:00
parent 0f790d4331
commit bc84559f1d

View File

@ -36,9 +36,7 @@ float getShadowFactor(vec3 pos, int index)
{
for (float j = -1.; j <= 1.; j += 1.)
{
// result += texture(shadowtex, vec4(shadowtexcoord + vec2(i,j) / shadow_res, float(index), d));
// Added a hack with j+1. to avoid ugly lines
result += texture(shadowtex, vec4(shadowtexcoord + vec2(i,j+1.) / shadow_res, float(index), d));
result += texture(shadowtex, vec4(shadowtexcoord + vec2(i,j) / shadow_res, float(index), d));
}
}