
Flocking and Swarming in Processing
1 year ago
Well, I had a day off of studying for finals so I decided to spend it working on a monstrous flocking algorithm. This video shows the progressive iterations over the day. I eventually got this O(n^4) complexity algorithm. It really blows up around n=200 and these clips are with 10,000 boids so they are not realtime. I need to optimize this and get it from 2D to 3D space. I am pretty sure I can get it down to O(n^2).
Sound --> Autechre
Sound --> Autechre
-
Vimeo: About / Blog / Developers / Jobs / Community Guidelines / Community Forums / Help Center / Site Map / Merchandise
/ Get Vimeo

Previous Week
What you are doing here has a great density and a great subtlety of color as well. Your patterns are really dramatic.
But are these objects programmed to "avoid" each other? That is what I have only recently been figuring out in qc, and I would have not a clue how to do it in Processing.
The ratio between the importance of those factors is what gives a flock like this its paticular behaviors.
There is a great flocking example sketch in the Processing examples if you want more info.