$ cat ./gen2-thumbnail.sh
#!/bin/sh
echo "選択してください!"
ls -l /home/web/public_html/epgrec/video/*.ts
echo ""
read OUTPUT
OUTFILE=`echo $OUTPUT | awk -F¥/ '{print $7}'`
THUMB1=/home/web/public_html/epgrec/thumbs/
/usr/bin/mplayer -nosound -ss 30 -frames 2 -vo jpeg:outdir=${THUMB1} -vf scale=160:90 ${OUTPUT}
mv ${THUMB1}00000002.jpg ${THUMB1}$OUTFILE.jpg
Comments