#!/bin/bash out="/mnt/drive2/myth3gp" darwin_username="your_username" darwin_host="www.your_server.com" darwin_dir="/usr/local/movies/" cd $out outfile=`echo $2 | sed 's/ /_/g' | sed 's/://g'` echo "START ($outfile): `date`" >> $out/runs.txt if [ ! -s "$1" -o "$outfile" == "" ] then echo "usage: $0 [nuv-file] [showname]" echo "END ($outfile): `date`" >> $out/runs.txt echo "" >> $out/runs.txt exit fi mencoder "$1" -nosound -ovc lavc -lavcopts vcodec=mpeg4 -vop expand=176:144,scale=176:-2 -o "$out/$outfile.avi" -ofps 12 mplayer -vo null -ao pcm -af resample=8000,volume=+6db:sc "$1" ffmpeg3gp -i "$out/$outfile.avi" -i $out/audiodump.wav -b 64 -ac 1 -ab 12 -map 0.0 -map 1.0 "$out/$outfile.3gp" rm -rf "$out/$outfile.avi" $out/audiodump.wav MP4Box -3gp -mtu 1450 -hint "$outfile.3gp" scp "$outfile.3gp" $darwin_username@$darwin_host:$darwin_dir echo "END ($outfile): `date`" >> $out/runs.txt echo "" >> $out/runs.txt