Skip to content

Commit

Permalink
refactor(TerrainMaterial): rename fogDepth -> vFogDepth
Browse files Browse the repository at this point in the history
  • Loading branch information
gchoqueux committed Oct 13, 2021
1 parent 1e2fc31 commit 7d162ec
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/Renderer/Shader/Chunk/fog_fragment.glsl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#if defined(USE_FOG)
float fogFactor = 1. - min( exp(-fogDepth / fogDistance), 1.);
float fogFactor = 1. - min( exp(-vFogDepth / fogDistance), 1.);
gl_FragColor.rgb = mix(gl_FragColor.rgb, fogColor, fogFactor);
#endif
2 changes: 1 addition & 1 deletion src/Renderer/Shader/Chunk/fog_pars_fragment.glsl
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#if defined(USE_FOG)
uniform vec3 fogColor;
uniform float fogDistance;
varying float fogDepth;
varying float vFogDepth;
#endif

0 comments on commit 7d162ec

Please sign in to comment.