Commit 87872329 authored by Alessandro Rubini's avatar Alessandro Rubini

doc/img: more figures (also logo), and change formats

pdftex has the very bad habit of picking png first, so we can't
have png images or the pdf version will be horrible. Thus, let's use
gif for the html (which is not picked by pdftex) and a .pdf generated
by our encapsulated postscript sources.

This adds the needed makefile and removes the previous pdf images,
which are regenerated in the next commit. We are also adding new
images where, including the logo used in the cover.
Signed-off-by: Alessandro Rubini's avatarAlessandro Rubini <rubini@gnudd.com>
Acked-by: 's avatarFederico Vaga <federico.vaga@gmail.com>
parent 2faf76e9
# pdftex picks png before pdf, and the result is crap.
# so let's use gif for the html version, instead of png (/me disgusted)
IN := $(wildcard *.ps *.eps)
PDF := $(patsubst %.ps,%.pdf,$(IN))
PDF := $(patsubst %.eps,%.pdf,$(PDF))
GIF := $(patsubst %.pdf,%.gif,$(PDF))
all: $(PDF) $(GIF)
%.pdf: %.ps
epstopdf $^
%.pdf: %.eps
epstopdf $^
%.gif: %.pdf
convert $^ $@
%!PS-Adobe-2.0 EPSF-1.2
%%Creator: Alessandro Rubini
%%Title: crap
%%BoundingBox: 0 0 200 200
%%Title: zio block dissected
%%BoundingBox: 0 0 270 340
%%EndComments
0 0 moveto
/minx 0 def
/miny 0 def
/maxx 600 def
/maxy 600 def
3 3 scale
0 setlinecap 1 setlinejoin
/grid {
gsave
.8 .8 .8 setrgbcolor
.2 setlinewidth
% vertical lines
minx 10 maxx {
dup
miny moveto maxy lineto stroke
} for
% horizontal lines
miny 10 maxy {
dup
minx exch moveto maxx exch lineto stroke
} for
/S {dup ==} def
/S2 {2 copy == ==} def
/S3 {3 copy == == ==} def
/S4 {4 copy == == == ==} def
/grid { % xmin xmax ymin ymax step
gsave
/step exch def
/maxy exch def
/miny exch def
/maxx exch def
/minx exch def
.8 .8 .8 setrgbcolor
.2 setlinewidth
% vertical lines
minx step maxx {
dup
miny moveto maxy lineto stroke
} for
% horizontal lines
miny step maxy {
dup
minx exch moveto maxx exch lineto stroke
} for
} def
/centerstring { % fontname width string -- fontsize
gsave
3 2 roll findfont setfont % width string
dup 3 1 roll % string width string
stringwidth pop div dup 3 1 roll % scale string scale
dup neg 0 exch rmoveto % scale string scale
3 2 roll findfont setfont % width string
dup 3 1 roll % string width string
stringwidth pop div dup 3 1 roll % scale string scale
dup neg 0 exch rmoveto % scale string scale
currentfont exch scalefont setfont % scale string
show
grestore
} def
/centeratsize { % x y string --
gsave
3 1 roll moveto
dup stringwidth pop 2 div neg 0 rmoveto show
grestore
gsave
3 1 roll moveto
dup stringwidth pop 2 div neg 0 rmoveto show
grestore
} def
/rect { % x y wid hei --
4 copy
gsave .8 .8 .8 setrgbcolor rectfill grestore
/hei exch def
/wid exch def
moveto
wid 0 rlineto 0 hei rlineto
wid neg 0 rlineto closepath
stroke
/wohs { % x y string --
gsave
dup stringwidth pop neg 0 rmoveto show
grestore
} def
/colrect { % r g b r g b x y wid hei --
newpath
/rhei exch def
/rwid exch def
/crect { % x y wid hei incolor outcolor --
/xxoutco exch def
/xxinco exch def
4 copy
xxinco rgb rectfill
xxoutco rgb
/hei exch def
/wid exch def
moveto
rwid 0 rlineto 0 rhei rlineto
rwid neg 0 rlineto closepath
gsave setrgbcolor fill grestore
setrgbcolor stroke
wid 0 rlineto 0 hei rlineto
wid neg 0 rlineto closepath
stroke
} def
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%grid
/zrect { % x y wid hei incolor outcolor letter --
/xxname exch def
/xxoutco exch def
/xxinco exch def
4 copy
xxinco rgb rectfill
xxoutco rgb
/hei exch def
/wid exch def
gsave
translate
0 0 moveto
wid 0 rlineto 0 hei rlineto
wid neg 0 rlineto closepath
stroke
/Helvetica-Bold findfont 8 scalefont setfont
wid 10 sub 3 moveto xxname show
grestore
} def
/zzrect { % x y wid hei name
aload pop zrect
} def
/arrow { % x y len angle --
/xxangle exch def
/xxlen exch def
gsave
translate
xxangle rotate
0 0 moveto
xxlen 0 lineto stroke
xxlen 0 moveto
-10 5 rlineto
0 -10 rlineto
closepath fill
grestore
} def
/carrow { % x y len angle color --
rgb
arrow
} def
% inner: S=255, V=193
% outer: S=255, V=116
/Linner [191 193 0] def
/Louter [115 116 0] def
% rifo V=225
/Linner [225 225 0] def
/Finner [105 195 0] def
/Fouter [63 116 0] def
% V=225
/Sinner [225 166 137] def
/Souter [116 85 71] def
% rifo: piu` rosa
/Sinner [255 180 205] def
/Souter [116 82 100] def
/Binner [166 124 83] def
/Bouter [97 72 48] def
/Tinner [226 73 81] def
/Touter [116 40 40] def
/Pinner [225 78 255] def
/Pouter [116 50 151] def
/rgb {
aload pop
255 div 3 1 roll
255 div 3 1 roll
255 div 3 1 roll
setrgbcolor
} def
/Cinner [0 220 224] def
/Couter [0 115 116] def
/Dinner [0 128 128] def
/Douter [0 64 64] def
/BLinner [94 94 225] def
/BLouter [0 0 116] def
% fix B (above is too blue
/BLinner [114 172 216] def
/BLouter [53 99 135] def
% again blue: much less saturated
/BLinner [177 199 216] def
/BLouter [53 99 135] def
% try again D
/Dinner [0 147 232] def
/Douter [0 64 64] def
/Dinner [30 115 144] def
/Dinner [62 146 175] def
/Douter [0 64 64] def
% fix C
/Couter Douter def
/Cinner [142 220 224] def
/L [ Linner Louter (L) ] def
/F [ Finner Fouter (F) ] def
/S [ Sinner Souter (S) ] def
/B [ Binner Bouter (B) ] def
/T [ Tinner Touter (T) ] def
/P [ Pinner Pouter (P) ] def
/C [ Cinner Couter (C) ] def
/D [ Dinner Douter (D) ] def
/BL [ BLinner BLouter (bl) ] def
/Ninner [ 220 220 220 ] def
/Nouter [ 128 128 128] def
/N [ Ninner Nouter (N) ] def
%0 300 0 400 10 grid
1.5 setlinewidth
0 0 0 setrgbcolor
%60 200 100 0 arrow
%60 200 100 30 arrow
180 20 60 200 D zzrect
180 240 60 60 C zzrect
%40 280 40 40 BL zzrect
40 280 40 40 BLinner BLouter (B) zrect
84 310 92 -12 BLouter carrow
84 290 120 -40 BLouter carrow
0 0 0 setrgbcolor
.5 setlinewidth
/Helvetica-Bold findfont 20 scalefont setfont
%1 1 1 .99 .99 .99 0 0 210 80 colrect
/bluforrect {.2 .2 .5 .8 .8 1} def
/greforrect {.2 .5 .2 .8 1 .8} def
/redforrect {.5 .2 .2 1 .8 .8} def
/Helvetica-Bold findfont 7 scalefont setfont
% righe di controllo
.5 setlinewidth 0 0 0 setrgbcolor
60 140 moveto 10 0 rlineto 20 20 rlineto 10 0 rlineto stroke
60 130 moveto 80 0 rlineto stroke
% arrowhead
100 160 moveto -6 1.5 rlineto 0 -3 rlineto closepath fill
140 130 moveto -6 1.5 rlineto 0 -3 rlineto closepath fill
%block
redforrect 30 120 30 30 colrect
45 140 (Block) centeratsize
greforrect 100 140 30 30 colrect
115 160 (Control) centeratsize
115 145 (512 b) centeratsize
bluforrect 140 40 30 100 colrect
155 130 (Data) centeratsize
/Helvetica-Bold findfont 16 scalefont setfont
%80 85 moveto gsave (Block) show grestore 70 0 rmoveto (Blue) show
%80 55 moveto gsave (Control) show grestore 70 0 rmoveto (Cyan) show
%80 25 moveto gsave (Data) show grestore 70 0 rmoveto (Darker) show
showpage
This diff is collapsed.
%!PS-Adobe-2.0 EPSF-1.2
%%Creator: Alessandro Rubini
%%Title: zio block control and data
%%BoundingBox: 0 0 220 190
%%EndComments
/S {dup ==} def
/S2 {2 copy == ==} def
/S3 {3 copy == == ==} def
/S4 {4 copy == == == ==} def
/grid { % xmin xmax ymin ymax step
gsave
/step exch def
/maxy exch def
/miny exch def
/maxx exch def
/minx exch def
.8 .8 .8 setrgbcolor
.2 setlinewidth
% vertical lines
minx step maxx {
dup
miny moveto maxy lineto stroke
} for
% horizontal lines
miny step maxy {
dup
minx exch moveto maxx exch lineto stroke
} for
} def
/centerstring { % fontname width string -- fontsize
gsave
3 2 roll findfont setfont % width string
dup 3 1 roll % string width string
stringwidth pop div dup 3 1 roll % scale string scale
dup neg 0 exch rmoveto % scale string scale
currentfont exch scalefont setfont % scale string
show
grestore
} def
/centeratsize { % x y string --
gsave
3 1 roll moveto
dup stringwidth pop 2 div neg 0 rmoveto show
grestore
} def
/wohs { % x y string --
gsave
dup stringwidth pop neg 0 rmoveto show
grestore
} def
/crect { % x y wid hei incolor outcolor --
/xxoutco exch def
/xxinco exch def
4 copy
xxinco rgb rectfill
xxoutco rgb
/hei exch def
/wid exch def
moveto
wid 0 rlineto 0 hei rlineto
wid neg 0 rlineto closepath
stroke
} def
/zrect { % x y wid hei incolor outcolor letter --
/xxname exch def
/xxoutco exch def
/xxinco exch def
4 copy
xxinco rgb rectfill
xxoutco rgb
/hei exch def
/wid exch def
gsave
translate
0 0 moveto
wid 0 rlineto 0 hei rlineto
wid neg 0 rlineto closepath
stroke
/Helvetica-Bold findfont 8 scalefont setfont
wid 10 sub 3 moveto xxname show
grestore
} def
/zzrect { % x y wid hei name
aload pop zrect
} def
/arrow { % x y len angle --
/xxangle exch def
/xxlen exch def
gsave
translate
xxangle rotate
0 0 moveto
xxlen 0 lineto stroke
xxlen 0 moveto
-10 5 rlineto
0 -10 rlineto
closepath fill
grestore
} def
/carrow { % x y len angle color --
rgb
arrow
} def
% inner: S=255, V=193
% outer: S=255, V=116
/Linner [191 193 0] def
/Louter [115 116 0] def
% rifo V=225
/Linner [225 225 0] def
/Finner [105 195 0] def
/Fouter [63 116 0] def
% V=225
/Sinner [225 166 137] def
/Souter [116 85 71] def
% rifo: piu` rosa
/Sinner [255 180 205] def
/Souter [116 82 100] def
/Binner [166 124 83] def
/Bouter [97 72 48] def
/Tinner [226 73 81] def
/Touter [116 40 40] def
/Pinner [225 78 255] def
/Pouter [116 50 151] def
/rgb {
aload pop
255 div 3 1 roll
255 div 3 1 roll
255 div 3 1 roll
setrgbcolor
} def
/Cinner [0 220 224] def
/Couter [0 115 116] def
/Dinner [0 128 128] def
/Douter [0 64 64] def
/BLinner [94 94 225] def
/BLouter [0 0 116] def
% fix B (above is too blue
/BLinner [114 172 216] def
/BLouter [53 99 135] def
% again blue: much less saturated
/BLinner [177 199 216] def
/BLouter [53 99 135] def
% try again D
/Dinner [0 147 232] def
/Douter [0 64 64] def
/Dinner [30 115 144] def
/Dinner [62 146 175] def
/Douter [0 64 64] def
% fix C
/Couter Douter def
/Cinner [142 220 224] def
/L [ Linner Louter (L) ] def
/F [ Finner Fouter (F) ] def
/S [ Sinner Souter (S) ] def
/B [ Binner Bouter (B) ] def
/T [ Tinner Touter (T) ] def
/P [ Pinner Pouter (P) ] def
/C [ Cinner Couter (C) ] def
/D [ Dinner Douter (D) ] def
/BL [ BLinner BLouter (bl) ] def
/Ninner [ 220 220 220 ] def
/Nouter [ 128 128 128] def
/N [ Ninner Nouter (N) ] def
%0 220 0 190 10 grid
1.5 setlinewidth
30 130 170 40 BL zzrect
35 145 20 20 C zzrect
55 145 140 20 D zzrect
20 80 50 20 BL zzrect
20 50 50 20 C zzrect
20 20 50 20 D zzrect
0 0 0 setrgbcolor
/Helvetica-Bold findfont 11 scalefont setfont
80 85 moveto gsave (The block is overall blue) show
/Helvetica-Bold findfont 16 scalefont setfont
80 55 moveto gsave (Control) show grestore 70 0 rmoveto (Cyan) show
80 25 moveto gsave (Data) show grestore 70 0 rmoveto (Darker) show
showpage
%!PS-Adobe-2.0 EPSF-1.2
%%Creator: Alessandro Rubini
%%Title: zio definitions and colors
%%BoundingBox: 0 0 250 240
%%EndComments
/S {dup ==} def
/S2 {2 copy == ==} def
/S3 {3 copy == == ==} def
/S4 {4 copy == == == ==} def
/grid { % xmin xmax ymin ymax step
gsave
/step exch def
/maxy exch def
/miny exch def
/maxx exch def
/minx exch def
.8 .8 .8 setrgbcolor
.2 setlinewidth
% vertical lines
minx step maxx {
dup
miny moveto maxy lineto stroke
} for
% horizontal lines
miny step maxy {
dup
minx exch moveto maxx exch lineto stroke
} for
} def
/centerstring { % fontname width string -- fontsize
gsave
3 2 roll findfont setfont % width string
dup 3 1 roll % string width string
stringwidth pop div dup 3 1 roll % scale string scale
dup neg 0 exch rmoveto % scale string scale
currentfont exch scalefont setfont % scale string
show
grestore
} def
/centeratsize { % x y string --
gsave
3 1 roll moveto
dup stringwidth pop 2 div neg 0 rmoveto show
grestore
} def
/wohs { % x y string --
gsave
dup stringwidth pop neg 0 rmoveto show
grestore
} def
/crect { % x y wid hei incolor outcolor --
/xxoutco exch def
/xxinco exch def
4 copy
xxinco rgb rectfill
xxoutco rgb
/hei exch def
/wid exch def
moveto
wid 0 rlineto 0 hei rlineto
wid neg 0 rlineto closepath
stroke
} def
/zrect { % x y wid hei incolor outcolor letter --
/xxname exch def
/xxoutco exch def
/xxinco exch def
4 copy
xxinco rgb rectfill
xxoutco rgb
/hei exch def
/wid exch def
gsave
translate
0 0 moveto
wid 0 rlineto 0 hei rlineto
wid neg 0 rlineto closepath
stroke
/Helvetica-Bold findfont 8 scalefont setfont
wid 10 sub 3 moveto xxname show
grestore
} def
/zzrect { % x y wid hei name
aload pop zrect
} def
/arrow { % x y len angle --
/xxangle exch def
/xxlen exch def
gsave
translate
xxangle rotate
0 0 moveto
xxlen 0 lineto stroke
xxlen 0 moveto
-10 5 rlineto
0 -10 rlineto
closepath fill
grestore
} def
/carrow { % x y len angle color --
rgb
arrow
} def
% inner: S=255, V=193
% outer: S=255, V=116
/Linner [191 193 0] def
/Louter [115 116 0] def
% rifo V=225
/Linner [225 225 0] def
/Finner [105 195 0] def
/Fouter [63 116 0] def
% V=225
/Sinner [225 166 137] def
/Souter [116 85 71] def
% rifo: piu` rosa
/Sinner [255 180 205] def
/Souter [116 82 100] def
/Binner [166 124 83] def
/Bouter [97 72 48] def
/Tinner [226 73 81] def
/Touter [116 40 40] def
/Pinner [225 78 255] def
/Pouter [116 50 151] def
/rgb {
aload pop
255 div 3 1 roll
255 div 3 1 roll
255 div 3 1 roll
setrgbcolor
} def
/Cinner [0 220 224] def
/Couter [0 115 116] def
/Dinner [0 128 128] def
/Douter [0 64 64] def
/BLinner [94 94 225] def
/BLouter [0 0 116] def
% fix B (above is too blue
/BLinner [114 172 216] def
/BLouter [53 99 135] def
% again blue: much less saturated
/BLinner [177 199 216] def
/BLouter [53 99 135] def
% try again D
/Dinner [0 147 232] def
/Douter [0 64 64] def
/Dinner [30 115 144] def
/Dinner [62 146 175] def
/Douter [0 64 64] def
% fix C
/Couter Douter def
/Cinner [142 220 224] def
/L [ Linner Louter (L) ] def
/F [ Finner Fouter (F) ] def
/S [ Sinner Souter (S) ] def
/B [ Binner Bouter (B) ] def
/T [ Tinner Touter (T) ] def
/P [ Pinner Pouter (P) ] def
/C [ Cinner Couter (C) ] def
/D [ Dinner Douter (D) ] def
/BL [ BLinner BLouter (bl) ] def
/Ninner [ 220 220 220 ] def
/Nouter [ 128 128 128] def
/N [ Ninner Nouter (N) ] def
%0 220 0 240 10 grid
1.5 setlinewidth
gsave 0 30 translate
20 170 50 20 L zzrect
20 140 50 20 F zzrect
20 110 50 20 S zzrect
20 80 50 20 B zzrect
20 50 50 20 T zzrect
20 20 50 20 P zzrect
0 0 0 setrgbcolor
/Helvetica-Bold findfont 16 scalefont setfont
80 175 moveto gsave (Luser) show grestore 70 0 rmoveto (Lemon) show
80 145 moveto gsave (Fops) show grestore 70 0 rmoveto (Forest) show
80 115 moveto gsave (Socket) show grestore 70 0 rmoveto (Salmon) show
80 85 moveto gsave (Buffer) show grestore 70 0 rmoveto (Brown) show
80 55 moveto gsave (Trigger) show grestore 70 0 rmoveto (Tomato) show
80 25 moveto gsave (Periph.) show grestore 70 0 rmoveto (Purple) show
grestore
% add network
20 20 50 20 N zzrect
0 0 0 setrgbcolor
/Helvetica-Bold findfont 16 scalefont setfont
80 25 moveto gsave (Network) show grestore 70 0 rmoveto (Neutral) show
showpage
%!PS-Adobe-2.0 EPSF-1.2
%%Creator: Alessandro Rubini
%%Title: zio logo
%%BoundingBox: 140 140 300 400
%%EndComments
5 5 scale
%%% my standard procedures from ../zio
/S {dup ==} def
/S2 {2 copy == ==} def
/S3 {3 copy == == ==} def
/S4 {4 copy == == == ==} def
/grid { % xmin xmax ymin ymax step
gsave
/step exch def
/maxy exch def
/miny exch def
/maxx exch def
/minx exch def
.8 .8 .8 setrgbcolor
.2 setlinewidth
% vertical lines
minx step maxx {
dup
miny moveto maxy lineto stroke
} for
% horizontal lines
miny step maxy {
dup
minx exch moveto maxx exch lineto stroke
} for
} def
/centerstring { % fontname width string -- fontsize
gsave
3 2 roll findfont setfont % width string
dup 3 1 roll % string width string
stringwidth pop div dup 3 1 roll % scale string scale
dup neg 0 exch rmoveto % scale string scale
currentfont exch scalefont setfont % scale string
show
grestore
} def
/centeratsize { % x y string --
gsave
3 1 roll moveto
dup stringwidth pop 2 div neg 0 rmoveto show
grestore
} def
/wohs { % x y string --
gsave
dup stringwidth pop neg 0 rmoveto show
grestore
} def
/crect { % x y wid hei incolor outcolor --
/xxoutco exch def
/xxinco exch def
4 copy
xxinco rgb rectfill
xxoutco rgb
/hei exch def
/wid exch def
moveto
wid 0 rlineto 0 hei rlineto
wid neg 0 rlineto closepath
stroke
} def
/zrect { % x y wid hei incolor outcolor letter --
/xxname exch def
/xxoutco exch def
/xxinco exch def
4 copy
xxinco rgb rectfill
xxoutco rgb
/hei exch def
/wid exch def
gsave
translate
0 0 moveto
wid 0 rlineto 0 hei rlineto
wid neg 0 rlineto closepath
stroke
/Helvetica-Bold findfont 8 scalefont setfont
wid 10 sub 3 moveto xxname show
grestore
} def
/zzrect { % x y wid hei name
aload pop zrect
} def
/arrow { % x y len angle --
/xxangle exch def
/xxlen exch def
gsave
translate
xxangle rotate
0 0 moveto
xxlen 0 lineto stroke
xxlen 0 moveto
-10 5 rlineto
0 -10 rlineto
closepath fill
grestore
} def
/carrow { % x y len angle color --
rgb
arrow
} def
/tan {dup sin exch cos div} def
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%0 100 0 150 10 grid
40 40 translate 10 10 scale
%%% the origin is in the bottom pit of the zed, and the width of it is 1.
% parameters are the length of the horizontal line (starting from the pit)
% and the angle: el is the length, al = akpha is the the length
/el 2 def
/al 55 def
% other less important parameters: tail width, line width, saturation (.5-1)
/tw .4 def
/lw .1 def
/sat .7 def
% "is reduced" alignes the corner of the base of the tip, else the center
/isred true def
% bg is the gray for bg. 1 == white
/bg .9 def
%%%%%%%%%%%%%%%%%%%%%%% the rest is calculated
/rsat 1 sat sub def
% diagonal width must be 1, so the leftmost point is -1/sin(al)
/elong 1 al sin div def
/centerx el elong add 2 div elong sub def
/centery el al tan mul 2 div def
/flip {
centerx centery translate
180 rotate
0 centerx sub 0 centery sub translate
} def
/dot {
moveto -0.05 -0.05 rmoveto
0 0 0 setrgbcolor
0.1 0 rlineto 0 0.1 rlineto -0.1 0 rlineto closepath fill
} def
/showcenter {
centerx centery dot
} def
% the arrow tip:
/tip {
0 0 moveto
el 0 lineto
al cos el mul
al sin el mul
lineto
closepath
fill
} def
% the arrow tail
/tail {
gsave
% move to the middle of the tail:
% x = (el + (el * cos(al))) / 2
% y = (el * sin(al)) / 2
/mx el el al cos mul add 2 div def
/my el al sin mul 2 div def
% length of the half-base segment
/tmp el mx sub def
/mlen tmp tmp mul my my mul add sqrt def
% reduce mlen by half width
/mred mlen tw 2 div sub def
mx my translate
al 2 div rotate
0 0 moveto
% here below: mlen aligns the center, mred the lower bound
/tlen isred { mred } { mlen } ifelse al 2 div tan mul def
0 tw 2 div neg moveto
tlen 0 rlineto 0 tw rlineto tlen neg 0 rlineto closepath fill
%0 0 dot
grestore
} def
% base line
/base {
gsave
0 0 0 setrgbcolor
lw setlinewidth
0 lw 2 div neg translate
elong neg -1 moveto el -1 lineto stroke
grestore
} def
/bgrect {
bg bg bg setrgbcolor
elong neg -1 moveto
el -1 lineto
el centery 2 mul 1 add lineto
elong el add neg 0 rlineto fill
} def
/whitezed {
gsave
1 setlinewidth 1 1 1 setrgbcolor
% the two horizontal lines
1 1 2 {
pop
elong 1 add neg -0.5 moveto
elong el add 2 add 0 rlineto stroke
flip
} for
centerx centery translate al rotate
-10 0 moveto 20 0 rlineto stroke
grestore
} def
%%%%%%%%%%%%%% what follows is the drawing itself
bgrect
whitezed
% base and arrow
sat rsat rsat setrgbcolor
tip tail base flip
rsat sat rsat setrgbcolor
tip tail base flip
showpage
%!PS-Adobe-2.0 EPSF-1.2
%%Creator: Alessandro Rubini
%%Title: zio pipeline
%%BoundingBox: 0 0 900 600
%%EndComments
/S {dup ==} def
/S2 {2 copy == ==} def
/S3 {3 copy == == ==} def
/S4 {4 copy == == == ==} def
/grid { % xmin xmax ymin ymax step
gsave
/step exch def
/maxy exch def
/miny exch def
/maxx exch def
/minx exch def
.8 .8 .8 setrgbcolor
.2 setlinewidth
% vertical lines
minx step maxx {
dup
miny moveto maxy lineto stroke
} for
% horizontal lines
miny step maxy {
dup
minx exch moveto maxx exch lineto stroke
} for
} def
/centerstring { % fontname width string -- fontsize
gsave
3 2 roll findfont setfont % width string
dup 3 1 roll % string width string
stringwidth pop div dup 3 1 roll % scale string scale
dup neg 0 exch rmoveto % scale string scale
currentfont exch scalefont setfont % scale string
show
grestore
} def
/centeratsize { % x y string --
gsave
3 1 roll moveto
dup stringwidth pop 2 div neg 0 rmoveto show
grestore
} def
/wohs { % x y string --
gsave
dup stringwidth pop neg 0 rmoveto show
grestore
} def
/crect { % x y wid hei incolor outcolor --
/xxoutco exch def
/xxinco exch def
4 copy
xxinco rgb rectfill
xxoutco rgb
/hei exch def
/wid exch def
moveto
wid 0 rlineto 0 hei rlineto
wid neg 0 rlineto closepath
stroke
} def
/zrect { % x y wid hei incolor outcolor letter --
/xxname exch def
/xxoutco exch def
/xxinco exch def
4 copy
xxinco rgb rectfill
xxoutco rgb
/hei exch def
/wid exch def
gsave
translate
0 0 moveto
wid 0 rlineto 0 hei rlineto
wid neg 0 rlineto closepath
stroke
/Helvetica-Bold findfont 8 scalefont setfont
wid 10 sub 3 moveto xxname show
grestore
} def
/zzrect { % x y wid hei name
aload pop zrect
} def
/arrow { % x y len angle --
/xxangle exch def
/xxlen exch def
gsave
translate
xxangle rotate
0 0 moveto
xxlen 0 lineto stroke
xxlen 0 moveto
-10 5 rlineto
0 -10 rlineto
closepath fill
grestore
} def
/carrow { % x y len angle color --
rgb
arrow
} def
% inner: S=255, V=193
% outer: S=255, V=116
/Linner [191 193 0] def
/Louter [115 116 0] def
% rifo V=225
/Linner [225 225 0] def
/Finner [105 195 0] def
/Fouter [63 116 0] def
% V=225
/Sinner [225 166 137] def
/Souter [116 85 71] def
% rifo: piu` rosa
/Sinner [255 180 205] def
/Souter [116 82 100] def
/Binner [166 124 83] def
/Bouter [97 72 48] def
/Tinner [226 73 81] def
/Touter [116 40 40] def
/Pinner [225 78 255] def
/Pouter [116 50 151] def
/rgb {
aload pop
255 div 3 1 roll
255 div 3 1 roll
255 div 3 1 roll
setrgbcolor
} def
/Cinner [0 220 224] def
/Couter [0 115 116] def
/Dinner [0 128 128] def
/Douter [0 64 64] def
/BLinner [94 94 225] def
/BLouter [0 0 116] def
% fix B (above is too blue
/BLinner [114 172 216] def
/BLouter [53 99 135] def
% again blue: much less saturated
/BLinner [177 199 216] def
/BLouter [53 99 135] def
% try again D
/Dinner [0 147 232] def
/Douter [0 64 64] def
/Dinner [30 115 144] def
/Dinner [62 146 175] def
/Douter [0 64 64] def
% fix C
/Couter Douter def
/Cinner [142 220 224] def
/L [ Linner Louter (L) ] def
/F [ Finner Fouter (F) ] def
/S [ Sinner Souter (S) ] def
/B [ Binner Bouter (B) ] def
/T [ Tinner Touter (T) ] def
/P [ Pinner Pouter (P) ] def
/C [ Cinner Couter (C) ] def
/D [ Dinner Douter (D) ] def
/BL [ BLinner BLouter (bl) ] def
/Ninner [ 220 220 220 ] def
/Nouter [ 128 128 128] def
/N [ Ninner Nouter (N) ] def
1.5 1.5 scale
%0 600 0 400 10 grid
/bigarr {
10 240 moveto
465 0 rlineto
0 -20 rlineto
120 60 rlineto
-120 60 rlineto
0 -20 rlineto
-465 0 rlineto
closepath
} def
% larger
/bigarr {
10 230 moveto
465 0 rlineto
0 -20 rlineto
120 70 rlineto
-120 70 rlineto
0 -20 rlineto
-465 0 rlineto
closepath
} def
5 setlinewidth
BLinner rgb
bigarr fill
BLouter rgb
bigarr stroke
gsave
600 -150 translate
-1 1 scale
BLinner rgb
bigarr fill
BLouter rgb
bigarr stroke
grestore
1.5 setlinewidth
0 0 0 setrgbcolor
20 40 50 330 L zzrect
100 40 100 330 F zzrect
230 40 100 330 B zzrect
360 40 100 330 T zzrect
490 40 90 330 P zzrect
0 0 0 setrgbcolor
70 130 500 {
300 30 0 arrow
} for
/Courier-Bold findfont 11 scalefont setfont
104 298 moveto (write) show
234 298 moveto (store_block) show
364 298 moveto (push_block) show
494 298 moveto (raw_io) show
490 -130 300 {
260 30 180 arrow
} for
456 258 moveto (data_done) wohs
326 258 moveto (retr_block) wohs
0 0 0 setrgbcolor
70 130 500 {
150 30 0 arrow
} for
/Courier-Bold findfont 11 scalefont setfont
104 148 moveto (read) show
234 148 moveto (retr_block) show
364 148 moveto (pull_block) show
494 148 moveto (raw_io) show
490 -130 300 {
110 30 180 arrow
} for
456 108 moveto (data_done) wohs
326 108 moveto (store_block) wohs
%%%% forgot alloc and destroy
/Courier-Bold findfont 9 scalefont setfont
.3 .3 .3 setrgbcolor
234 310 moveto (alloc_block) show
326 248 moveto (free_block) wohs
326 120 moveto (alloc_block) wohs
234 136 moveto (free_block) show
true {
%%% redo the outlines over the rest
5 setlinewidth
BLinner rgb
%bigarr fill
BLouter rgb
bigarr stroke
gsave
600 -150 translate
-1 1 scale
BLinner rgb
%bigarr fill
BLouter rgb
bigarr stroke
grestore
} if
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment