I've a script to do some snapshots but the time it does so is very different...
once i got a snapshot under 1 sec, on the other hand it took 3 sec, but nothing else changed, i didnt even move the cursor or something.
I put the script on a ramdisk and its faster, but still swing from under 1 sec to 2 secs. What else can I do to make it faster or just steady?
until [ $A -eq 1 ]
do
## TIME
START=$(date +%s%N)
##/TIME
xwd -name "Windows XP Professional" | xwdtopnm 2>/dev/null | pnmtopng > picci`echo $COUNTI`.png
echo "picnumber "$COUNTI
COUNTI=`expr $COUNTI + 1`
if [ $COUNTI -gt 250 ]
then
COUNTI=0
fi
##TIME
END=$(date +%s%N)
DIFF=$(( $END - $START ))
echo "It took $DIFF seconds"
##/TIME
done
