tutorial

we got that fishy feeling!

Parts 1 and 2 of this tutorial are available via the following links:

Hello again. It's time for more fun with Softimage. This is the last installment of my three part underwater bonanza. Today, we'll learn how to use particle to make a lively underwater scene featuring a school of fish.

Before beginning, you'll need to get the Go-with-the-flow plugin and if you use NT, you'll also need the particle QFE update. You can find these items on the Softimage web site.

the particle system
We'll start out by making the particle system that will be used to guide the fish in Softimage. Open particle and set the animation segment to 120 frames. Then create a square emitter by hitting "New" in the source card and choosing square in the geometry field. Scale it out to be large, about 50 units square and rotate it 90 degrees in X. Set the generation to surface and the speed to 60. You can preview the system now (you'll want to zoom out so you can see the whole thing). You should have a stream of particles flowing out of your square in a straight line.

figure 1

In order to add a little curve to you particles you'll need to use a magnetic field. Go to the global magnetic setting (F12) and set it to .600. Set the magnetic value in the particle perimeters of the particle card to 1. If you preview now, you'll notice that your particles make a sharp turn to the right.

figure 2

Now we'll key the emission so that the school won't go on forever. We'll key the emission rate at 5000 for frame one and zero for frame five. To do this, set the time slider to frame one. Now go to the Source card and set the rate to 5000 and set a key. Move the time slider to frame five, set the rate to zero and set another key. Now if you preview the system, you'll see a blob of particles that all moves in synch.

figure 3

It's starting to look like a pretty good school of fish, but we need to add a little randomness to the system. On the Particle card, go to the noise section. The P, S, and A in this section stand for position, speed and acceleration. We'll set the S value to 2 to give the fish a little randomness. If you preview now you'll see a great looking school of fish.

figure 4

All that's left now is to create the .bpf file to bring into Softimage. Go to the file card and hit the render button. Under "Output Type", set for "Binary Particle File" and make sure that the sequence is set for 120 frames. Pick the database to save in and the filename in the "Output" section and hit the "Render Sequence" button. That's it! Now on to Softimage.

animating the fish
The first thing you'll need is a good model of a fish. If you've been following along, you'll already have the great model that you made in parts one and two. If not, I've built a quick fish for you to use (fish-bod.hrc). Even if you did go through the hassle of making that thing, you may want to use the new model to cut down on render time (that's what I'm going to do). You'll want to throw some textures on him before you start. You can check my previous tutorial for some tips and a hi-res texture map.

Set your animation segment to 120 frames (bottom right corner of the screen). Get your fish model and center it on the global origin. The first thing you need to do is to orient the fish properly. Rotate it in Y so that the mouth is pointing to the right. Freeze the rotation and make sure that the X-axis (the red one) is oriented along the fish's backbone, pointing toward his head. Also make sure that his Y-axis (green) is pointing up. You can make an object's axis visible by choosing Model>Show>Center.

Use the Draw>Curve>B_Spline and draw a sine wave like the one pictured here in the front window.

figure 5

Use gridlock to make a really accurate curve. With the spline selected, use Motion>Effects>Wave>Create to make a wave effect. Pick planar as the type. Use the defaults, except set the velocity to 30 and the start and end frames at -1000 and 1000 respectively. Use periodicity in space. Now attach the wave to the fish by using Motion>Effects>Wave>Attach>Branch and picking the fish. Transform the wave icon until it waves your fish nicely along the backbone. Voila, you have a swimming fish!

bringing in the particles
Now you need to use Go-With-The-Flow to bring the particles into Softimage. Hide the fish and the wave. Get a primitive null and use Duplicate>Repetition (with no transformations) to make 50 copies of the null. Delete the original null. Select the root of the null hierarchy you made and choose Motion>FcrvEdit>+GoWithTheFlow. Hit the "Select Particle Bpf File" bar and pick the .bpf you made in particle. Turn off "scale by particle size" and "Set frame start, end step". Hit "Read file" and then "Go!" and exit when it's done. Now all your nulls are animated, having picked up the motion from particle. Now we need to convert the nulls animation into paths. In the schematic window, multi-select the nulls (not the root) and choose Motion>Path>Conv.toPathTransl. Now you'll have a forest of paths for your school of fish to swim on.

figure 6

creating the school
Select your swimming fish and Choose Duplicate>Instance_Repetition. As you did with the nulls, make 50 instances with no transformations. You'll soon be doing a lot of assignments between the paths and the instances. So to make things easier, you'll want to go to the schematic window and line up the instance hierarchy right underneath the paths in the null hierarchy (you'll thank me later). This is how I set up my schematic.

figure 7

Select the first instance and assign it to the first path using Motion>Path>PickPath (ok for 120 frames), then tangency constrain the first instance to the first path using Actor>Constraint>Tangency. Go to the perspective window and be sure that the fish is swimming in the right direction. If he's swimming sideways or backward, it's because you weren't paying attention and his center is pointed in the wrong direction (go stand in the corner). You need to rotate and freeze the fish model so that his X-axis is pointing toward his head and his Y-axis is pointing up and then remake your instances. If all is well with your fish's swimming performance, you can go back and assign paths and constraints to the rest of the instances, assigning an instance to each path and then going back and constraining the tangency of each instance to its respective path.

Wait a second, that's it! You're done! Go to the perspective window and check out your awesome animation. You can use the paths to help you position the camera. Have the fish start just off screen to the left and the swim through the camera. For finishing touches you can add depth fading and some seabed. You can try the Captain Nemo material shader on the seabed if you're feeling adventurous. Motion blur will also help you get the best results.

Here's my scene with all the trimmings:

figure 8
Click here to download the final animation in AVI format.



Peter Arisman is a digital artist working and living in Seattle. He can be contacted at reepete@geocities.com and has a web site at www.3dartists.com.


[ galleries | archives | downloads | about | contacts ]
[ back to main page | back to contents page ]