u(t) is called 60 times per second.
t: Elapsed time in seconds.
S: Shorthand for Math.sin.
C: Shorthand for Math.cos.
T: Shorthand for Math.tan.
R: Function that generates rgba-strings, usage ex.: R(255, 255, 255, 0.5)
c: A 1920x1080 canvas.
x: A 2D context for that canvas.
more dynamic wavebreak that aligns with perspective: for(j=20,h=96;h--;)for(v=54;v--;x.fillRect(h*j,v*j,j,j))z=S(t&h/(v*2))*255,x.fillStyle=R(n=v*4<=h-t*9%(v+1)?0:255-z,n-64,v*3>h?64:255-z,.01)
I like the feel you created here. Almost like a city pop album cover, but it moves!
u(t) is called 60 times per second.
t: elapsed time in seconds.
c: A 1920x1080 canvas.
x: A 2D context for that canvas.
S: Math.sin
C: Math.cos
T: Math.tan
R: Generates rgba-strings, ex.: R(255, 255, 255, 0.5)