Lawrence Livermore National Laboratory

13. How do I make a movie of my data?

There are a two ways to save a movie in VisIt and the one you use depends on the complexity of the movie that you want to make. The easiest way to save a movie in VisIt is to set up your plots just how you want them to look and then use the Save movie wizard in VisIt's GUI. If you prefer to use VisIt's batch movie making utility, you can set up your plots as usual and save a session file by selecting Save session from the File menu. A session file contains the information that VisIt needs to recreate the image on your screen. For the purposes of this example, assume that you saved a session file called movie.session. To make a movie of it, open a command line shell and type:

  • visit -movie -geometry 800x800 -sessionfile movie.session -format mpeg -output mymovie -fps 30

Note that you may have to include the complete path to VisIt if you are running VisIt on Windows. The command given above launches VisIt's command line interface (CLI) recreates your plots using the session file that you saved and then steps through each frame in your animation and saving an image file for each frame of the animation. After the frames are saved to disk, VisIt attempts to combine the individual movie frames into a single MPEG movie file. Note that VisIt cannot create MPEG movies on Windows at this time. You can, however, create ppm, jpeg, or tiff image files using the -format command line flag and then import the image files into your favorite movie making software. Making movies using this session-file-based approach allows you to save out relatively complex animations with little effort. You can use VisIt's Keyframe editor window to set up fly-by animations and to make various plot attributes vary over time.

Another approach to making movies with VisIt is to write a Python script that tells VisIt everything that you want to do in your movie. This approach is more work but you have much more control over plot and operator attributes as well as when time advances in the animation. We plan to make it easier to do more complex animations using the session file approach, but for now if you need very complex animations, you can use Python scripting. If you wrote a Python script called, you could make VisIt save your movie as tiff files by typing the following command in a command line shell:

  • visit -movie -geometry 1024x1024 -s -format tiff -output mymovie -fps 30

VisIt's Python Interface Manual documents all of the functions in the VisIt Python extension and includes examples of how to do common plotting and movie-making operations. If you need more examples of how to write Python scripts for VisIt, download the VisIt source code distribution and look for Python scripts in the visitpy/examples directory. If the two current ways of making movies sound too difficult, don't worry. We plan to enhance VisIt in the next few versions so it is easier to make movies.