diff --git a/tools/make-ptraccel-graphs.sh b/tools/make-ptraccel-graphs.sh index b96f9e56..2e6c73af 100755 --- a/tools/make-ptraccel-graphs.sh +++ b/tools/make-ptraccel-graphs.sh @@ -7,48 +7,54 @@ if [[ -e '$tool' ]]; then echo "Unable to find $tool" exit 1 fi +speeds="-1 -0.75 -0.5 -0.25 0 0.5 1" outfile="ptraccel-linear" -for speed in -1 -0.75 -0.5 -0.25 0 0.5 1; do +for speed in $speeds; do $tool --mode=accel --dpi=1000 --filter=linear --speed=$speed > $outfile-$speed.gnuplot done $gnuplot < $outfile-$dpi.gnuplot done $gnuplot < $outfile-$speed.gnuplot +done + $gnuplot < $outfile-$speed.gnuplot - echo "\"$outfile-$speed.gnuplot\" using 1:2 title '$speed', \\" - done -) +speeds="$speeds" +fname(s)=sprintf("$outfile-%s.gnuplot", s) +plot for [s in speeds] fname(s) using 1:2 title s, \ + EOF outfile="ptraccel-trackpoint" $tool --mode=accel --dpi=1000 --filter=linear > $outfile-mouse.gnuplot -for constaccel in 1 2 3; do - dpi=$((1000/$constaccel)) - $tool --mode=accel --dpi=$dpi --filter=trackpoint > $outfile-trackpoint-$constaccel.gnuplot +for speed in $speeds; do + $tool --mode=accel --speed=$speed --filter=trackpoint > $outfile-$speed.gnuplot done $gnuplot <