#this script extracts frames for all movies (.mov) in the current folder.
# one image per frame per second saved to disk
for MOVIE in *.mov
do
if [ -f "$MOVIE" ]; then
FILENAME="${MOVIE%.*}"
echo $FILENAME
if [ ! -d "$FILENAME" ]; then
mkdir "$FILENAME"
fi
cd "$FILENAME"
#modify fps if you want to extract more than one frame per second
ffmpeg -i ../$MOVIE -vf fps=1 $FILENAME"_"%05d.png
cd ..
fi
done