diff --git a/assets/voxygen/shaders/fluid-vert.glsl b/assets/voxygen/shaders/fluid-vert.glsl index 2692e463a2..da46679608 100644 --- a/assets/voxygen/shaders/fluid-vert.glsl +++ b/assets/voxygen/shaders/fluid-vert.glsl @@ -25,7 +25,7 @@ void main() { float((v_pos_norm >> 16) & 0x1FFFu) ) + model_offs; f_pos.z *= min(1.0001 - 0.02 / pow(tick.x - load_time, 10.0), 1.0); - f_pos.z -= 25.0 * pow(distance(focus_pos.xy, f_pos.xy) / view_distance.x, 20.0); + f_pos.z -= min(32.0, pow(distance(focus_pos.xy, f_pos.xy) / view_distance.x, 20.0)); f_col = vec3( float((v_col_light >> 8) & 0xFFu), diff --git a/assets/voxygen/shaders/lod-terrain-vert.glsl b/assets/voxygen/shaders/lod-terrain-vert.glsl index 84456c45aa..8d259b1edb 100644 --- a/assets/voxygen/shaders/lod-terrain-vert.glsl +++ b/assets/voxygen/shaders/lod-terrain-vert.glsl @@ -17,7 +17,7 @@ out float f_light; void main() { f_pos = lod_pos(v_pos + vec2(0, -v_pos.x * 0.5)); - f_pos.z -= 1.0 / pow(distance(focus_pos.xy, f_pos.xy) / (view_distance.x * 0.95), 20.0); + f_pos.z -= min(32.0, 1.0 / pow(distance(focus_pos.xy, f_pos.xy) / (view_distance.x * 0.95), 20.0)); f_light = 1.0; diff --git a/assets/voxygen/shaders/sprite-vert.glsl b/assets/voxygen/shaders/sprite-vert.glsl index 6838b47669..aa7ec1b313 100644 --- a/assets/voxygen/shaders/sprite-vert.glsl +++ b/assets/voxygen/shaders/sprite-vert.glsl @@ -30,7 +30,7 @@ void main() { vec3 sprite_pos = (inst_mat * vec4(0, 0, 0, 1)).xyz; f_pos = (inst_mat * vec4(v_pos * SCALE, 1)).xyz; - f_pos.z -= 1.0 * pow(distance(focus_pos.xy, f_pos.xy) / (view_distance.x * 0.95), 20.0); + f_pos.z -= min(32.0, pow(distance(focus_pos.xy, f_pos.xy) / (view_distance.x * 0.95), 20.0)); // Wind waving f_pos += inst_wind_sway * vec3( diff --git a/assets/voxygen/shaders/terrain-vert.glsl b/assets/voxygen/shaders/terrain-vert.glsl index b1b46a6836..47322fd3bc 100644 --- a/assets/voxygen/shaders/terrain-vert.glsl +++ b/assets/voxygen/shaders/terrain-vert.glsl @@ -21,7 +21,7 @@ void main() { f_pos = vec3((uvec3(v_pos_norm) >> uvec3(0, 8, 16)) & uvec3(0xFFu, 0xFFu, 0x1FFFu)) + model_offs; f_pos.z *= min(1.0001 - 0.02 / pow(tick.x - load_time, 10.0), 1.0); - f_pos.z -= 1.0 * pow(distance(focus_pos.xy, f_pos.xy) / (view_distance.x * 0.95), 20.0); + f_pos.z -= min(32.0, pow(distance(focus_pos.xy, f_pos.xy) / (view_distance.x * 0.95), 20.0)); f_col = vec3((uvec3(v_col_light) >> uvec3(8, 16, 24)) & uvec3(0xFFu)) / 255.0;