Pixel rain effect (Vanilla JS)

screenshot1.png

A javascript experiment which shows falling pixels with their speed mapped to the original image’s brightness.

We split the image into coloured RGBA pixels and use these values to calculate a human percieved lightness value which is then used to adjust the speed of a travelling pixel.

View on GitHub | Demo