#!/bin/sh
# Scriptec greb webcam
cur_date=`date \+\%d.\%m.\%Y`
cur_time=`date \+\%H:\%M`
cam_dir=/home/virtual/denz/htdocs/cam
/usr/local/bin/vid -d /dev/ugen0 --small | pnmtojpeg --quality=72 --optimize --smooth 10 \
--progressive --comment="TiraNET Office (67700, Ukraine, Belgorod-Dnestrovsky, P/O Box 4) "\
> /tmp/webcam_shot.jpg
rm -f ${cam_dir}/camout.jpg
/usr/local/bin/convert -normalize -fill white -font helvetica -antialias \
-draw "text 45,230 'WebCam in kladovka [ $cur_time @ $cur_date ]'" \
/tmp/webcam_shot.jpg ${cam_dir}/camout.jpg
rm -f /tmp/webcam_shot.jpg
chown -R denz:www ${cam_dir}/*
URL: http://www.bsdportal.ru/viewtopic.php?t=3721
Обсуждается: http://www.opennet.ru/tips/info/823.shtml
|