StageTools - Documentation (StageManager/Tutorial) [Prev][Top][Up][Next]


Creating an Animated GIF

Now we are ready to make the animated GIF file for this movie (assuming you have installed the tools necessary to do this). The first thing we want to do is set the size for our movie. The default Geomview window is too large for our purposes, so use the Other item in the Image/Size menu to set the size to 200 x 200; the Geomview window show shrink accordingly. Make sure that the Image/Type menu is set to GIF, and set Image/Scale to 2:1.1 Finally, select the Animated GIF Parameters item in the Options menu, and set the animation to loop forever with a frame delay of 8.

To make the movie, select Save Frames and Make AnimGIF from the Action menu. This will cause the individual frames to be recorded, and then will combine them into an animated GIF file.2 When you are ready, press the Execute button to create the movie. The execution window will list the frames as they are saved, and then will show the frames being put together by gifmerge. Note, however, that gifmerge does not produce optimized GIF files, due to the patent on the compressed GIF format owned by UNISYS, so the resulting file is much larger than it should be. You may want to post-process it with another utility that will compress the file for you. One such tool is Gif Builder on the Macintosh.

After StageManager has generated the animated GIF file, you can view it by selecting the animated GIF viewer in the Tools menu. By default, this will launch Netscape to view the file, but this can be customized. You should see the blue cube spinning around its vertical axis. Congratulations, you have made your first movie!

You may notice, however, that there is a slight pause when the cube gets a quarter of the way around. This is because the first and last frames of the movie are actually the same (since the starting and ending positions of the cube both look the same when you rotate by 90 degrees). When the animation loops, there are two identical frames in a row, which makes the cube seem to pause at that point. We can overcome this by leaving out one of the frames: change the Sequence command to

    Sequence {XY $pi/2} 10 -nozero
which will prevent the initial frame (frame zero) of the sequence from being recorded. Save the frames and make the animation again; you should see a smoother-looking result.


1

This causes the frames to be generated twice as large as needed then scaled down to the desired size; this causes anti-aliasing to be performed on the image, which is not done by Geomview.

2

These two actions are separate, because saving frames is time-consuming and you might need to remake the movie with different settings (particularly if you make an MPEG movie) before you get the result you want. There is no need to resave the frames each time.



[HOME] StageTools Documentation web pages
Created: 08 Sep 2001
Last modified: 09 Sep 2001 00:02:56
Comments to: dpvc@union.edu
[Next] Creating an MPEG Movie
[Up] A Short StageManager Tutorial
[Prev] Scripting Your First Movie<