Flyweight particles are awesome

I was putting together some  interactive sketches to  throw up on the wall at a party recently and came up with this – I hope you like it!  Usage: click on the animation and press a key for fullscreen. Esc to return.

Get Adobe Flash player

While this sketch was being projected on the wall, there were two striking aspects that kept coming up with people. First, the brain tries to match any visual pattern to even the most vaguely-related audio rhythm. Despite knowing full-well how it works, it seemed to match up with nearly any audio track well enough to appear the same. Second, it is amazing how complicated the result of a few simple rules can be! This is just a field of 50,000 particles being influenced by a ‘force map’ – as though the particles were being viewed from above and rolling down a rough mountain-scape.   The particles bear a resemblance to smoke, water, sparks and fur – despite never being designed to do so!