| 1 |
root |
1.1 |
#!/bin/sh |
| 2 |
|
|
|
| 3 |
root |
1.2 |
WIDTH=15 |
| 4 |
|
|
BLUR=4.5,8 |
| 5 |
root |
1.1 |
|
| 6 |
|
|
draw() { |
| 7 |
|
|
white=$1 |
| 8 |
|
|
w=$2 |
| 9 |
|
|
|
| 10 |
|
|
convert -size 152x152 xc:$white -matte -fill none -draw "matte 0,0 reset" -channel rgba \ |
| 11 |
|
|
+fill -stroke $white \ |
| 12 |
root |
1.3 |
-draw "stroke-antialias 1 stroke-width $WIDTH circle 75.5,75.5 35.75,75" \ |
| 13 |
root |
1.1 |
-blur $BLUR \ |
| 14 |
|
|
circle-$w.png |
| 15 |
|
|
|
| 16 |
|
|
convert -size 152x152 xc:$white -matte -fill none -draw "matte 0,0 reset" -channel rgba \ |
| 17 |
|
|
+fill -stroke $white \ |
| 18 |
root |
1.3 |
-draw "stroke-antialias 1 stroke-width $WIDTH roundrectangle 37.5,37.5 113.5,113.5 8,8" \ |
| 19 |
root |
1.1 |
-blur $BLUR \ |
| 20 |
|
|
square-$w.png |
| 21 |
|
|
|
| 22 |
|
|
convert -size 152x152 xc:$white -matte -fill none -draw "matte 0,0 reset" -channel rgba \ |
| 23 |
|
|
+fill -stroke $white \ |
| 24 |
root |
1.3 |
-draw "stroke-antialias 1 stroke-width $WIDTH line 40,40 111,111 line 111,40 40,111" \ |
| 25 |
root |
1.1 |
-blur $BLUR \ |
| 26 |
|
|
cross-$w.png |
| 27 |
|
|
|
| 28 |
|
|
R=46 |
| 29 |
root |
1.3 |
A=$(perl -e "print 75.5-$R") |
| 30 |
|
|
B=$(perl -e "print 75.5 + $R * sin 120/360*4*atan2 1,1") |
| 31 |
|
|
C=$(perl -e "print 75.5 - $R * sin 120/360*4*atan2 1,1") |
| 32 |
|
|
D=$(perl -e "print 75.5 + $R * 0.5") |
| 33 |
root |
1.1 |
convert -size 152x152 xc:$white -matte -fill none -draw "matte 0,0 reset" -channel rgba \ |
| 34 |
|
|
+fill -stroke $white \ |
| 35 |
root |
1.3 |
-draw "stroke-antialias 1 stroke-width $WIDTH polygon 75.5,$A $B,$D $C,$D" \ |
| 36 |
root |
1.1 |
-blur $BLUR \ |
| 37 |
|
|
triangle-$w.png |
| 38 |
|
|
} |
| 39 |
|
|
|
| 40 |
|
|
draw white w |
| 41 |
|
|
draw black b |
| 42 |
|
|
|
| 43 |
|
|
optipng -q -o9 circle* square* cross* triangle* |