All examples · Experiments

Ripples

What this example shows

Move the mouse and small ripples trail behind it; click for a big drop. Each ring bends the picture of the bottom as it passes and catches the light, and the sun plays on the stones.

The water remembers nothing between frames. Each of the last eight drops is four numbers (where, when, how hard) in a vec4 uniform, and the sprite's material works out from them where every ring is now.

The bottom is painted by the example on a canvas.

Starting