Better caustic movement

This commit is contained in:
Joshua Barretto 2022-01-21 01:06:11 +00:00
parent 63f6af0621
commit 51323cde38

View File

@ -291,7 +291,7 @@ void main() {
if (faces_fluid) {
vec3 wpos = f_pos + focus_off.xyz;
vec3 spos = (wpos + wpos.z * vec3(sun_dir.xy, 0)) * 0.05;
reflected_light += max(1.0 - pow(abs(noise_3d(vec3(spos.xy, tick.x * 0.1 + dot(sin(wpos.xy * 0.2), vec2(1)) * 0.1)) - 0.5) * 10, 0.001), 0)
reflected_light += max(1.0 - pow(abs(noise_3d(vec3(spos.xy, tick.x * 0.1 + dot(sin(wpos.xy * 0.8), vec2(1)) * 0.05)) - 0.5) * 10, 0.001), 0)
* 500
* cam_attenuation
* sun_diffuse;