#!/bin/sh

FILES=$@
if [ "$FILES" = "" ] ; then
  FILES="elmts"
fi

TEX=csplain; export TEX

for FILE in $FILES ; do
  rm $FILE.mpx
  mpost $FILE
  mptopdf $FILE.1
  cp $FILE.1 $FILE-1.pdf ../../figs/
done

./mp $FILE
mv tmp.eps $FILE.eps
eps2png_crop $FILE.eps

exit


