#https://www.shadertoy.com/view/ldjXzK

pixels = W:1024 H:1024

x = from -0.5 to 0.5 W
y = from 0.5 to -0.5 H

dt = 1.0

amp = 0.05 + dt * 0.1
freq = 7.0
warp = 12.0 * x + 4.0 * dt
    
r = 0.2 + dt * amp * cos(atan2(x, y) * freq - warp);
leaves = smoothstep( r, r + 0.2 + dt * amp, length2(x, y) );
    
r = 1.0*leaves
g = 0.4*leaves
b = 0.1*leaves

k = 0.0025	
distort_leaves =  1.0 - smoothstep( k, k + 0.1 + dt * amp, abs( x ) )
distort_trunk  = -0.5 - smoothstep( 0.02, 0.019, y )
w = 1.0 - ( distort_leaves ) * ( distort_trunk )

r = r*w
g = g*w
b = b*w
