First of all you have to make a lot of PostScript files, which eventually will be the movie. Make sure they have all the same size. You can control the size by using the program XV. This program may also be used to change the format of a file.
The names of the files should be image.0000.ps, image.0001.ps, etc., where image may be any chosen name.
Now it depends on which procedure you want to follow. To use makempeg or whirlgif you need gif-files and for the use of mpeg2encode you need ppm-files. To convert a lot of ps-files to gif-files and ppm-files you may use the following script:
#!/usr/bin/sh for name in `ls *.ps` do ps2gifppm -col $name doneSo now you have ps-, gif- and ppm-files. Remove the ones you don't need!
Now you are ready to make the movie. But first you have to make a choice about the format of that movie-file. Will it be GIF or MPG?
The command you need is whirlgif: a quick program that reads a series of gif files, and produces a single gif file composed of those images.
Usage: whirlgif [-v] [-trans index] [-time delay] [-o outfile] [-loop] [-i incfile] file1 [-time delay] file2 options: -v verbose mode -loop [count] add the Netscape 'loop' extension. -time delay inter-frame timing. -disp [method] Set disposal method, see below -trans index set the colormap index 'index' to be transparent -o outfile write the results to 'outfile' -i incfile read a list of names from 'incfile'
If you don't specify an output file, the GIF will be sent to stdout. This is a good thing if you're using this in a CGI script, a very bad thing if you run this from a terminal and forget to redirect stdout.
The output file (if any) and -loop _MUST_ be specified before any gif images.
You can specify several delay statements on the command line to change the delay between images in the middle of an animation, e.g
whirlgif -time 5 a.gif b.gif c.gif -time 100 d.gif -time 5 e.gif f.gifAlthough it's generally considered to be evil, you can also specify several transparency statements on the command line, to change the transparent color in the middle of an animation. This may cause problems for some programs.
To read more information: click on the location:
You decided you want to make an mpeg movie. Still you have two choices on how to do that:
The command:
makempeg -fs 1 -fi 1 -fe 20 -base image -ext gifwill make the file image.mpg, which you can play with the command: mpeg_play image.mpg.
Explanation of the command:
Usage: makempeg [-fs start] [-fe end] [-fi increment] [-base basename] [-ext extension] fs = fe = fi = 1 base = imageTip: If the speed of the video is too high, you can duplicate the gif-files one or more times and run the makempeg command again, with the adjusted numbers.
To use the mpeg2encode program you need the ppm-files and a parameter file, for example mpeg-1.par. You will find examples of parameter files in directory
/usr/local/talib/mpegCopy the file to the directory of your ppm-files and edit the file. Do NOT delete any lines in this file! The lines that need editing are:
The horizontal and vertical sizes you can obtain by viewing the ppm-file with xv:
xv image.ppmPut the mouse in the picture and click your right-mouse button. Point to image size and drag your mouse to set size. Here you see the dimensions of your picture. It should be obvious that the horizontal and vertical size of every file to use should be the same.
Now you are ready to give the following command:
mpeg2encode MPEG-1.par image.mpgTo read more information: click on the location: