ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/cvsroot/Gtk2-GoBoard/data/draw-marks
Revision: 1.1
Committed: Wed Jun 25 04:41:10 2008 UTC (16 years ago) by root
Branch: MAIN
Log Message:
add support for MARK_CROSS, cleanup

File Contents

# Content
1 #!/bin/sh
2
3 WIDTH=11
4 BLUR=4,4
5
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 -draw "stroke-antialias 1 stroke-width $WIDTH circle 75,75 35.75,75" \
13 -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 -draw "stroke-antialias 1 stroke-width $WIDTH roundrectangle 35.5,35.5 116.5,116.5 8,8" \
19 -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 -draw "stroke-antialias 1 stroke-width $WIDTH line 35,35 117,117 line 117,35 35,117" \
25 -blur $BLUR \
26 cross-$w.png
27
28 R=46
29 A=$(perl -e "print 76.5-$R")
30 B=$(perl -e "print 76.5 + $R * sin 120/360*4*atan2 1,1")
31 C=$(perl -e "print 76.5 - $R * sin 120/360*4*atan2 1,1")
32 D=$(perl -e "print 76.5 + $R * 0.5")
33 set -x
34 convert -size 152x152 xc:$white -matte -fill none -draw "matte 0,0 reset" -channel rgba \
35 +fill -stroke $white \
36 -draw "stroke-antialias 1 stroke-width $WIDTH polygon 76.5,$A $B,$D $C,$D" \
37 -blur $BLUR \
38 triangle-$w.png
39 }
40
41 draw white w
42 draw black b
43
44 optipng -q -o9 circle* square* cross* triangle*