#! /bin/csh -f

set VERS = $1
set I = $2
cd movies
ffmpeg -y -qscale 5 -r 20 -b 9600 -i ../images/$VERS'_'%04d.jpg $VERS'_'$I.mpg
ffmpeg  -y -qscale 5 -r 20 -b 9600 -i ../images/$VERS'_'%04d.jpg $VERS'_'$I.mp4

rm latest.mpg latest.mp4
ln $VERS'_'$I.mpg latest.mpg
ln $VERS'_'$I.mp4 latest.mp4
