ISF - Shadertoy - Moon reflection ls33zj
const float xw = 0.1;
const float yw = 0.15;
const float xf = 3.0;
const float yf = 18.0;
const float xs = 0.5;
const float ys = -0.4;
const vec4 m = vec4(0.93, 0.9, 0.8, 1.0);
const vec4 w = vec4(0.03, 0.01, 0.3, 1.0);
void main()
{
vec2 uv = gl_FragCoord.xy;
uv.x = 2.0 * (uv.x - RENDERSIZE.x / 2.0);
uv /= RENDERSIZE.yy;;
uv.y = mod(uv.y * 2.0, 1.0) - 0.5;
uv *= 2.0;
if (gl_FragCoord.y / RENDERSIZE.y < 0.5) {
uv += vec2(xw * sin(xf * (uv.x - xs * TIME)),
yw * cos(yf * (uv.y - ys * TIME)));
}
gl_FragColor = mix(m, w,
vec4(smoothstep(0.1, 0.15, dot(uv, uv))));
}