1 uniform sampler2D uTexGarbage;
10 const vec3 uCamera = vec3(0.0);
12 #include "common_world.glsl"
13 #include "motion_vectors_fs.glsl"
17 compute_motion_vectors();
19 vec3 rd = normalize(aNorm);
21 float fmove = g_time * 5.0;
22 vec2 cloudplane = (rd.xz / (rd.y*sign(rd.y))) * 0.025;
23 vec4 clouds1 = texture( uTexGarbage, cloudplane + vec2(0.1,0.4)*fmove*2.0 );
24 vec4 clouds2 = texture( uTexGarbage, cloudplane*2.0 + vec2(0.3,0.1)*fmove );
26 float cloud_d = max(clouds1.b*clouds2.r -0.2 - clouds2.g*0.4,0.0);
27 float cloud_e = pow(cloud_d,1.5)*pow(abs(rd.y),0.3)*2.0;
29 oColour = vec4( clearskies_sky( -rd ) ,1.0);
31 vec3 cloud_colour = mix( mix(g_nightsky_colour.rgb,vec3(1.0),g_day_phase),
32 g_sunset_colour.rgb, g_sunset_phase );
34 oColour.rgb = mix( oColour.rgb, cloud_colour, cloud_e );