This repository has been archived by the owner on Feb 7, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 20
/
dc.eps
135 lines (115 loc) · 1.93 KB
/
dc.eps
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
%!PS-Adobe-3.0 EPSF-3.0
%%BoundingBox: 5 5 400 600
%%LanguageLevel: 2
%This is an attempt to produce an 2D tile
%based on empty square, filled square,
%a square filled with a quarter of a circle
%and a square filled with the complement of a
%square of a circle
%The tiles may be rotated with 90 degres
/s1{
0 0 5 5 rectstroke
}def
/s1N{
gsave
1 0 0 setrgbcolor
0 0 5 5 rectfill
grestore
}def
/q1{
gsave
0 0 5 0 90 arc
0 0 lineto
closepath
1 0 0 setrgbcolor
fill grestore
s1
}def
/q2{
gsave
5 0 5 90 180 arc
5 0 lineto
closepath
1 0 0 setrgbcolor
fill grestore
s1
}def
/q3{
gsave
5 5 5 180 270 arc
5 5 lineto
closepath
1 0 0 setrgbcolor
fill grestore
s1
}def
/q4{
gsave
0 5 5 270 0 arc
0 5 lineto
closepath
1 0 0 setrgbcolor
fill grestore
s1
}def
/q1N{
s1N
gsave
0 0 5 0 90 arc
0 0 lineto
closepath
1 1 1 setrgbcolor
fill grestore
s1
}def
/q2N{
s1N
gsave
5 0 5 90 180 arc
5 0 lineto
closepath
1 1 1 setrgbcolor
fill grestore
s1
}def
/q3N{
s1N
gsave
5 5 5 180 270 arc
5 5 lineto
closepath
1 1 1 setrgbcolor
fill grestore
s1
}def
/q4N{
s1N
gsave
0 5 5 270 0 arc
0 5 lineto
closepath
1 1 1 setrgbcolor
fill grestore
s1
}def
/sym [ //q1 //q1N //q2 //q2N //q3 //q4 //q3N //q4N //s1N //s1 ] def
/range sym length def
/rNum {rand range mod} def
%Initial setup
5 5 scale
0 setlinewidth
2 2 translate
%Start drawing
%horizontal boxes >> 15
%veritcal boxes >> 22
23 {
14 {
% select a random symbol to be drawn
sym rNum get exec
5 0 translate
} repeat
%go up one row
-70 5 translate
} repeat
showpage
%%EOF