Better aurora

This commit is contained in:
Joshua Barretto 2020-11-26 00:38:40 +00:00
parent 77a39d74d4
commit a5c37262dd

View File

@ -86,7 +86,7 @@ vec4 cloud_at(vec3 pos, float dist, out vec3 emission) {
#endif
}
float mist_sun_access = 0.5 + turb_noise;
float mist_sun_access = 0.5 + turb_noise * 0.5;
float mist_moon_access = mist_sun_access;
sun_access = mix(cloud_sun_access, mist_sun_access, clamp(mist * 20000, 0, 1));
moon_access = mix(cloud_moon_access, mist_moon_access, clamp(mist * 20000, 0, 1));
@ -109,6 +109,9 @@ vec4 cloud_at(vec3 pos, float dist, out vec3 emission) {
#if (CLOUD_MODE >= CLOUD_MODE_LOW)
emission_alt += (noise_3d(vec3(wind_pos.xy * 0.00003 + cloud_tendency * 0.2, time_of_day.x * 0.0001)) - 0.5) * 6000;
#endif
#if (CLOUD_MODE >= CLOUD_MODE_HIGH)
emission_alt += (noise_3d(vec3(wind_pos.xy * 0.0005 + cloud_tendency * 0.2, emission_alt * 0.0001 + time_of_day.x * 0.0005)) - 0.5) * 1000;
#endif
float tail = (texture(t_noise, wind_pos.xy * 0.00005).x - 0.5) * 10 + (z - emission_alt) * 0.001;
vec3 emission_col = vec3(0.6 + tail * 0.6, 1.0, 0.3 + tail * 0.2);
float emission_nz = max(texture(t_noise, wind_pos.xy * 0.00003).x - 0.6, 0) / (10.0 + abs(z - emission_alt) / 40);