mirror of
https://github.com/Merlin1809/Eclipse-Shader.git
synced 2026-10-11 01:38:20 +08:00
fix issue where puddles do not use flat normals
This commit is contained in:
1 parent
74a0e0f0c8
commit
196f0c2fcc
1 file changed
+3
-3
@@ -693,7 +693,7 @@ void applyPuddles(
|
||||
float halfWet = min(wetnessAmount,1.0);
|
||||
float fullWet = clamp(wetnessAmount - 2.0,0.0,1.0);
|
||||
// halfWet = 1.0;
|
||||
// fullWet = 1.0;
|
||||
// fullWet = 0.0;
|
||||
float noise = texture2D(noisetex, worldPos.xz * 0.02).b;
|
||||
|
||||
|
||||
@@ -1289,8 +1289,8 @@ void main() {
|
||||
|
||||
#if defined DEFERRED_SPECULAR
|
||||
vec3 specularNoises = vec3(BN.xy, blueNoise());
|
||||
vec3 specularNormal = slopednormal;
|
||||
if (dot(slopednormal, (feetPlayerPos_normalized)) > 0.0) specularNormal = FlatNormals;
|
||||
vec3 specularNormal = normal;
|
||||
if (dot(normal, (feetPlayerPos_normalized)) > 0.0) specularNormal = FlatNormals;
|
||||
|
||||
FINAL_COLOR = specularReflections(viewPos, feetPlayerPos_normalized, WsunVec, specularNoises, specularNormal, SpecularTex.r, SpecularTex.g, albedo, FINAL_COLOR, shadowColor, lightmap.y, hand, isWater || (!isWater && isEyeInWater == 1), flashLightSpecularData);
|
||||
#endif
|
||||
|
||||
Reference in new issue
Block a user