![]() I really wanted to animation water, so I began with a sphere. One could visualize it as a large water baloon. It seemed like the most natural object for the subject. To make a splash of water, I drop the sphere, and break it open on a ground plane. After all this was thought up, I realized it wasn't particularly exciting, but I wanted to do water like stuff. The sphere only has 42 vertices, but to make water
look convincing, I wanted to use a lot of particles. Karl Sims used
60,000 in Particle Dreams. As a result, I had to figure out
what to do with all the other particles. I decided that all the other
particles would just hide out(with transparency equal to 1.0). As
each particle representing a vertex of the sphere collided with the ground,
that particle would turn into water and bouce off of the ground with 120
other particles. I repeated this for each vertex, and the effect
was that the particle would break up into many many pieces. I ended
up using 10,000, when I finally got the renderer working.
|
There are two main force fields in this animation.
One is gravity and the other is a random force. The dropping of the
sphere at the beginning of the animation is just gravity. After the
particles crash, they bounce back with reduced velocity. They also
vary in the x and y direction based on some random number.![]() The river before the water fall is started at random velocities, but those velocities are only in the positive X direction. This creates the illusion of water. There is no movment in the Y or Z directions, but the particles are placed on random spaces along the Y axis to give the river some width. Once the particles fall off the edge of the water fall, they are subject gravity. To make the effect of the water look more convincing, I change the color of the falling water to something lighter than the original color. After dropping the "water balloon" I wanted to drain
the water, as if it were spiraling into a sink. I had some problems
trying to think of the equations. Finally I looked the equations
up in a physics book. By the time I figured out how to do the math,
I didn't want to take the extra time to fix it. In fact, I would
have had time, but I struggled so long with the rendering that it will
have to find it's way into another animation.
|
This section posed to be the hardest
of the three, but since the particles only bounce off of a horizontal plane,
it turned out to be really easy.
![]() The other collision of particles took place when the sphere crashes into the ground. At the point of impact, as described above, the paricles spliter off into 120 pieces, change color to blue, and spread out. |
Inventor leaves you feeling like a director of
a movie or photo shoot. The first thing I saw when I ran particles
was a ball. I tried the rotation control and I got a faded ball,
then a wall. A normal question at this point might be, "Why does
a rotation transform my primitive from a sphere to a plane?" The
discovery phase was slow, but eventually I realized that the camera starts
at 0,0,0. Soon after that I the navigation began to make sense.
It's not the most intuitive. One has to think like a camera.![]() Once I figured out the controls, it became apparent to me that the real fun stuff was in the code. It was very well documented. With the exception that the colors had to be floats between 0 and 1, rather than an integer from 0 to 255 as the comments suggested. Many of the calls were named such that one could guess their meaning. Insight and the Inventor Mentor proved also to be highly valuable. I experimented with specular highlights, cubes, but in the end used diffuse color and spheres. Spheres looked more convincing in terms of water anyway. I spent almost all of my time in Inventor using
bounding box mode. It was a must, even on the O2s, when I used anything
more than 500 particles.
|