Widgets, Gadgets, Toys, Design and Technology by Adam Bidwell...

Butterflies

Flocking is the term for the collective motion of a large number of self-propelled entities[1]. This is a classic computer modelling problem and it is used extensively in computer animation and game development, to increase realism in mathematically generated movement. I started this project in December 2006, nearly 25 years since the problem was first modelled on a computer[2]. The main objective of this project was to emulate this behaviour and develop simple algorithms that can be re-used in many other projects. The chosen subject matter is a group of winged insects which resemble butterflies. During the animation, the butterflies begin to swarm together one by one. As the mouse cursor is drawn across the animation, the butterflies will be attracted towards it. The butterflies follow three simple rules during flight:

  1. Fly toward the centre of the flock.
  2. Avoid collision with any other butterflies.
  3. Accelerate or decelerate to match the velocity of the flock as a whole.

Progress

Note: Playback requires the Java plug-in for your browser, so please install the plug-in if you nothing appears to happen when you click the link, or if you experience playback difficulties.

ANIMATION ONE

ANIMATION TWO

The original animation seemed a little too cruel. The butterflies will follow the mouse forever without taking a rest. As a result, I created a third animation, which depicts birds flocking around the mouse pointer as before. This time, if the pointer is moved off the bottom of the screen the birds will land and take a rest before rejoining the rest of the flock.

ANIMATION THREE (birds)

Acknowledgements, references and notes:

[1] Wikipedia - Flocking http://en.wikipedia.org/wiki/Flocking_(behavior)

[2] Craig Reynolds - Boids http://www.red3d.com/cwr/boids/

screenshot: