Flocking in C4D
Motion, Uncategorized, Virtual Entertainment, experimental February 3rd. 2008, 3:58pm
As part of my experimentations with Xpresso for my Virtual Entertainment class, I have been working with Thinking Particles to try and emulate flocking birds. This started with research into what has been already done. The biggest help came from Tim Clampham, who had a basic flocking setup with Xpresso started. The problem was that in his example, he used big spheres to work as deflections for the birds to go around, and it doesnt look very natural. My first goal was to try and fix that problem.
Here the result looks a bit more natural. I used 4 different spherical gravities placed in the path of the birds similar to the way that the original used deflections. There is still the problem however of getting the individual birds to behave more individually. They all turn at exactly the same time, and more importantly are all going about the same speed.
In this example, I have removed the 4 gravity nulls from the path of the birds so that the changes are more apparent. Here I attached the position of a gravity sphere to the current particle group. This way there is a gravity sphere that stays within the flock. The result was unexpected. The birds stay in a group, but seem to sort of revolve around each other. It makes the flock look even more natural, however the way that they revolve around each other seems to look predictable. If on one side of the flock there are a number of birds moving upward, on the other side the same amount are moving down.
In this example, I have kept the following gravity sphere, but added a sin formula to it so that it fades in and out, making the swarming flow of the internal flock less consistent and predictable. Also, I have added another emiter from the same location with the same settings, except it emits just 1 particle. I have attached another gravity sphere to it and this also has the pulsing formula to it. With this second gravity sphere, it makes the flock grow and shrink.
Here in my final experiment, I have added back the 4 spheres of gravity. These in addition to the internal swarming effects of the flock, makes for a pretty natural Thinking Particle flocking system within Cinema.
Leave a Reply
You must be logged in to post a comment.