[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Making Movies: problems
From: |
Marcus G. Daniels |
Subject: |
Re: Making Movies: problems |
Date: |
11 Sep 1998 09:40:49 -0700 |
>>>>> "PJ" == Paul Johnson <address@hidden> writes:
PJ> I was under the impression, until I read your note, that it was
PJ> possible to write a png file in batch mode. Not so?
Strictly speaking it is, the question is of what? You can't
write a PNG file of the logical structure of a space object, for example.
PJ> Also, I've got a bunch of png's coming out of a simulation, how do
PJ> I make it a movie?
Here's the script I use (adapted slightly from a script from Nelson Minar).
You need the netpbm utilities, the fuzzy bitmap utilities, and pngtopnm.
Note the first argument is for fbm2fli. The typical use of this is to
specify the display area for the FLI movie.
#!/bin/bash
# make a .fli file from the given list of .png files
# requires pngtopnm, pnmtorast, fboctree, fbm2fli
# usage: png2fli "fbm2fli arguments" 0.png 1.png ...
fbm2fliparams="$1"
shift
list="$@"
output=output.fli
octdata=/tmp/octree.$$
giflist=/tmp/fbm2fli.$$
if [ -e $output ]; then
echo "$output already exists, you need to remove it."
exit 1;
fi
echo -n 'Building the octree data. '
for f in $list; do
base=${f%.png}
echo -n "$base "
pngtopnm $f | ppmtotga | tga2fbm | fboctree -a $octdata
done # 2> /dev/null
echo
echo -n 'Converting PNG files to 8 bit GIFs. '
for f in $list; do
base=${f%.png}
tmpbase=/tmp/$base
nf=${tmpbase}.$$.gif
echo -n "${base} "
pngtopnm $f | ppmtotga | tga2fbm | fboctree -G $octdata > $nf
echo $nf >> $giflist
done # 2> /dev/null
echo
echo "Creating $output from the GIFs"
fbm2fli $fbm2fliparams $giflist $output > /dev/null 2> /dev/null
echo "Cleaning up"
echo giflist: $giflist
rm `cat $giflist`
rm $giflist $octdata
exit 0;
==================================
Swarm-Support is for discussion of the technical details of the day
to day usage of Swarm. For list administration needs (esp.
[un]subscribing), please send a message to <address@hidden>
with "help" in the body of the message.
==================================
Re: Making Movies: problems, Paul Johnson, 1998/09/10