-+-+-+-+-+-+-+-+ START OF PART 18 -+-+-+-+-+-+-+-+ X456 50 LN X458 52 LN X459 54 LN X459 56 LN X458 59 LN X456 61 LN X454 62 LN X452 62 LN XPL X468 62 MV X468 49 LN XPL X468 58 MV X471 61 LN X472 62 LN X475 62 LN X477 61 LN X478 58 LN X478 49 LN XPL X483 43 MV X502 43 LN X502 44 LN X483 44 LN X483 43 LN XPL X516 68 MV X514 68 LN X512 67 LN X511 64 LN X511 49 LN XPL X509 62 MV X515 62 LN XPL X537 62 MV X537 49 LN XPL X537 59 MV X536 61 LN X534 62 LN X531 62 LN X529 61 LN X528 59 LN X527 56 LN X527 54 LN X528 52 LN X529 50 LN X531 49 LN X534 49 LN X536 50 LN X537 52 LN XPL X557 59 MV X555 61 LN X554 62 LN X551 62 LN X549 61 LN X547 59 LN X546 56 LN X546 54 LN X547 52 LN X549 50 LN X551 49 LN X554 49 LN X555 50 LN X557 52 LN XPL X571 68 MV X571 53 LN X572 50 LN X573 49 LN X575 49 LN XPL X568 62 MV X574 62 LN XPL X590 62 MV X588 61 LN X586 59 LN X585 56 LN X585 54 LN X586 52 LN X588 50 LN X590 49 LN X593 49 LN X594 50 LN X596 52 LN X597 54 LN X597 56 LN X596 59 LN X594 61 LN X593 62 LN X590 62 LN XPL X607 62 MV X607 49 LN XPL X607 56 MV X608 59 LN X610 61 LN X612 62 LN X615 62 LN XPL X0 1 MV X0 116 LN X810 116 LN X810 1 LN X0 1 LN XPL X847 64 MV X849 65 LN X851 68 LN X851 49 LN XPL X868 68 MV X865 67 LN X863 64 LN X863 60 LN X863 57 LN X863 53 LN X865 50 LN X868 49 LN X870 49 LN X872 50 LN X874 53 LN X875 57 LN X875 60 LN X874 64 LN X872 67 LN X870 68 LN X868 68 LN XPL Xshowpage X%%EndDocument X 195 -33 a X endTexFig X595 1239 a Fq(Figure)11 b(6.1:)j(A)e(structure)e(content)h(diagram.)108 X1373 y Fi(LABEL)19 b(\("start-structcontent)q("\))108 1423 Xy(SET_LOCAL_TRANSFORMA)q(TION_3)q(\(unit)i(matrix\))108 1522 Xy(TEXT)e(\(heading)g(of)g(structure)g(content)g(diagram\))108 X1622 y(`5Bthe)g(following)g(3)g(elements)g(are)f(repeated)i(for)e(each)h X(element)g(box:`5D)108 1672 y(SET_PICK_IDENTIFIER\()q(elemen)q(t)i(number\)) V108 X1721 y(TEXT)e(\(element)g(type\))108 1771 y(FILL_AREA_SET)108 X1821 y(TEXT)g(\(element)g(number\))54 1921 y(LABEL\("end-structcont)q(ent"\) V) X0 2041 y Fq(The)10 b(picture)f(is)g(placed)h(in)f(the)g(currently)g(open)g X(structure)g(starting)f(at)h(the)g(current)h(element)g(pointer)n(.)j(If)c X(there)h(is)f(no)g(structure)0 2091 y(open,)i(an)h(error)f(is)g(reported)g X(and)g(there)h(is)f(no)g(action.)k(If)c(the)g(function)f(was)i(successful,)g XFi(error)g Fq(is)g(set)f(to)g(zero.)0 2260 y Fr(6.3)59 b(Example)0 X2381 y Fq(The)12 b(demonstration)e(program)h Fi(stctest)i Fq(illustrates)c X(the)j(use)f(of)g(the)g(functions)f(in)h(this)f(library)m(.)0 X2956 y(13th)22 b(May)m(,)12 b(1992)636 b(39)839 b(2.01)p eop X%%Page: 40 41 Xbop 0 349 a Fj(Chapter)24 b(7)0 585 y Fs(The)29 b(PHIGS)g(T)-10 Xb(opology)27 b(Library)0 835 y Fq(This)11 b(module)f(provides)f(a)j(quick)e X(and)g(easy)i(way)f(of)f(checking)g(a)i(PHIGS)e(structure)g(network)g(by)g X(automatically)g(producing)0 885 y(a)h(topology)d(diagram.)15 Xb(The)c(topology)d(diagram)i(illustrates)f(a)i(structure)f(hierarchy)g(by)f X(drawing)h(the)g(structures)g(as)h(nodes)f(in)0 935 y(a)i(graph)f(and)g X(using)g(arcs)h(\(lines\))e(to)h(represent)g(the)h(execute)g(connections)f X(between)g(the)g(structures.)0 1014 y(This)g(module)g(includes)g(functions)f X(for:)64 1134 y Fl(\267)21 b Fq(Drawing)13 b(\(into)f(a)i(PHIGS)g X(structure\))f(a)h(topology)e(diagram)i(of)f(a)h(speci\256ed)h(structure)e X(network.)22 b(There)15 b(are)f(three)104 1184 y(dif)o(ferent)c(styles)h(of) Vg X(topology)e(diagram)j(available.)64 1267 y Fl(\267)21 b Fq(Drawing)10 Xb(the)i(topology)d(of)i(a)g(speci\256ed)h(list)f(of)g(PHIGS)g(`60paths'.)64 X1350 y Fl(\267)21 b Fq(Interactively)10 b(`60tidying')f(an)i(automatically)g X(produced)g(topology)e(diagram,)i(in)g(order)g(to)g(make)h(it)f(more)g X(legible.)64 1433 y Fl(\267)21 b Fq(Storing)9 b(and)j(retrieving)e(topology) Vf X(diagrams)i(to)g(\256les.)64 1516 y Fl(\267)21 b Fq(Highlighti)o(ng)8 Xb(speci\256ed)k(structure)f(nodes)g(in)g(topology)e(diagrams.)0 X1685 y Fr(7.1)59 b(An)17 b(automatic)e(structur)o(e)g(network)h(visualiser)0 X1806 y Fq(Normally)m(,)e(PHIGS)f(structures)g(are)h(used)f(to)g(represent)h X(separate)g(logical)f(components)g(of)g(the)g(model,)h(and)f(they)g(may)h(be V) X0 1856 y(linked)d(to)h(form)g(hierarchies,)h(using)f(the)g XFk(execute)i(structur)n(e)e Fq(element.)19 b(A)13 b(collection)e(of)h X(structures)g(linked)f(hierarchically)0 1906 y(is)g(called)h(a)h XFk(structur)n(e)f(network)q Fq(,)g(and)f(has)h(the)g(topology)d(of)j(a)g XFk(dir)n(ected)g(acyclic)h(graph)p Fq(.)j(This)11 b(is)h(illustrated)e(in)h X(Figure)g(7.1,)0 1956 y(which)i(shows)h(a)h(house)f(modelled)f(using)g(a)i X(structure)e(network)g(comprising)g(four)g(structures;)h(Figure)g(7.1\(a\))g X(shows)f(the)0 2006 y(visual)e(appearance)i(of)f(the)f(model,)h(and)g(\(b\)) Vf X(its)g(logical)g(structure,)g(which)h(is)f(hierarchical.)17 Xb(The)12 b(house)g(comprises)g(a)g(door)0 2055 y(and)f(a)g(window)m(,)g(and) Vg X(the)f(door)g(has)i(within)d(it)h(a)h(doorknob.)j(Figure)c(7.1\(c\))h(shows) Vg X(the)g(elements)g(in)f(each)i(of)f(the)g(structures)0 2105 Xy(involved,)d(and)h(\(d\))g(the)f(PHIGS)h(commands)h(used)f(to)g(create)h X(the)f(network.)k(The)d(`60house')f(structure)f(has)h(three)g(elements:)14 Xb(the)0 2155 y(\256rst)d(is)g(a)h(polyline)d(to)i(draw)g(the)g(walls,)g(and) Vh X(the)f(second)g(and)h(third)d(elements)j(are,)h(respectively)m(,)e X(references)i(to)e(the)g(`60door)r(')0 2205 y(and)g(`60window')e(structures. V)15 Xb(The)d(`60door)r(')d(structure)i(has)g(two)f(elements,)i(the)f(\256rst)g(a) Vg X(polyline)f(to)g(draw)h(the)g(door)f(frame,)i(and)0 2255 y(the)h(second)h(a) Vh X(reference)g(to)e(the)g(`60doorknob')f(structure.)21 b(The)15 Xb(`60doorknob')c(and)j(`60window')e(structures)h(are)i(at)e(the)h(lowest)0 X2304 y(levels)d(of)g(the)g(hierarchy)m(,)h(and)g(contain)e(only)g(polyline)g X(elements.)0 2383 y(The)g(`60house')f(is)h(a)g(simple)f(example)i(of)e(a)h X(structure)f(network,)g(but)g(it)g(does)h(illustrate)e(the)h(general)h X(problem)f(of)g(documenting)0 2433 y(PHIGS)f(structure)f(networks.)14 Xb(Of)7 b(the)h(four)f(dif)o(ferent)g(representations)g(of)h(the)f(house)h(in V) Xf(Figure)g(7.1,)i(only)e(\(a\))h(is)g(immediately)0 2483 y(available\320it)i X(is)h(the)g(output)f(from)h(the)g(PHIGS)g(program.)16 b(In)11 Xb(most)g(applications,)g(however)n(,)h(the)f Fk(logical)f(structur)n(e)h XFq(of)g(the)0 2533 y(model)g(is)h(important,)e(and)i(it)e(is)i(likely)e(that V) Xh(the)g(sort)g(of)g(stylised)g(representations)g(shown)g(in)g(\(b\))g(and)g X(\(c\))h(will)e(be)i(required)0 2583 y(as)g(much)h(as)f(the)g(\256nal)f(view V) Xh(of)g(the)f(model.)17 b(This)12 b(is)f(especially)h(true)g(during)e(program V) Xi(development.)k(In)c(order)f(to)g(derive)0 2632 y(these)f(representations,) Vf X(either)g(the)g(source)g(code)h(of)f(the)f(program)h(must)g(be)h(manually)e X(inspected,)i(or)f(the)g(program)g(textually)0 2682 y(modi\256ed)h(\(and)h X(subsequently)e(compiled)h(and)h(linked\))e(to)h(procedurally)g(inquire)f X(the)h(information)f(from)h(the)h(CSS.)g(Neither)0 2732 y(are)k(very)f X(satisfactory)g(solutions:)k(although)13 b(both)g(techniques)g(provide)h X(information)e(about)h(the)h(hierarchical)h(nature)f(of)912 X2956 y(40)p eop X%%Page: 41 42 Xbop 0 -137 a Fq(PHIGS)11 b(T)m(oolkit)f(User)i(Manual)1235 Xb(PTK/100)87 -33 y X 26702205 14917438 657817 394690 51243991 28615065 startTexFig X87 -33 a X%%BeginDocument: newhouse.ps X /vltdict 5 dict def vltdict begin /gray 256 array def /index 0 def end X /setcolorindex `7Bvltdict exch /index exch put `7D def X /selcolorindex `7Bvltdict begin gray exch get 255 div setgray end `7D def X /setvlt `7Bvltdict begin setrgbcolor gray index currentgray 255 mul put end V `7D def X /decr `7B2 copy get 1 sub put `7D def /setvltmult `7Bsetcolorindex dup X vltdict /index get add setcolorindex `7Bvltdict /index decr setvlt `7D repe Vat `7D def X 1 1 1 0 0 0 1 0 0 1 0.5 0 1 1 0 0 1 0 0 1 1 0 0 1 1 0 1 X 0.47 0.27 0 1 1 1 11 0 setvltmult 64 `7B0 0 0`7D repeat 64 11 setvltmult X 64 `7B0 0 0`7D repeat 64 75 setvltmult 64 `7B0 0 0`7D repeat 64 139 setvltm Vult X 53 `7B0 0 0`7D repeat 53 203 setvltmult /polyline `7B3 1 roll newpath movet Vo X 1 sub `7Blineto`7D repeat stroke`7D def /textdict 5 dict def textdict begin X /font /Courier findfont def end /text `7Bmoveto show`7D def X /selecttext `7Btextdict begin font angle matrix rotate X width height matrix scale matrix concatmatrix makefont setfont end`7D def X /settextatt `7Btextdict begin /angle exch def /width exch def /height exch V def X end`7D def /filldict 2 dict def /setfillatt `7Bfilldict begin /border exch V def X /interior exch def end`7D def /fillareaset `7Bfilldict /interior get selcol Vorindex X newpath `7B currentfile token pop dup 0 gt X `7B currentfile token pop currentfile token pop moveto 1 sub X `7B currentfile token pop currentfile token pop lineto `7D repeat `7D `7Bex Vit `7D ifelse X `7D loop gsave eofill grestore filldict /border get selcolorindex stroke`7D V def X /dot `7Bnewpath 0 360 arc closepath fill`7D def X 31.6 26.87 translate 72 300 div dup scale 0 setlinecap 2 setlinejoin X /tmpstr 1 string def /tstr 1024 string def /ymax 3331 def X /scaleimage `7B0 ymax translate dup scale 0 ymax neg translate`7D def X /putrow `7Bvltdict begin matrix currentmatrix 4 1 roll 3 scaleimage transla Vte X `5B 1 0 0 1 0 0 `5D 1 8 3 -1 roll X `7Bgray currentfile tmpstr readhexstring pop 0 get get X cvi tmpstr exch 0 exch put tmpstr`7D image setmatrix end`7D def X /pr `7Bvltdict begin matrix currentmatrix 4 1 roll 3 scaleimage translate X `5B 1 0 0 1 0 0 `5D 1 8 3 -1 roll `7Bcurrentfile tstr readline pop /t exch V def X 0 1 t length 1 sub `09`7B dup t exch get 33 sub 255 mul 93 div round cvi X `09 t 3 1 roll put `09`7D for t `7D image setmatrix end`7D def /#copies 1 V def gsave X 1.000 1.000 1.000 0.000 0.000 0.000 1.000 0.000 0.000 1.000 0.500 0.000 1.0 V00 X 1.000 0.000 0.000 1.000 0.000 0.000 1.000 1.000 0.000 0.000 1.000 1.000 0.0 V00 X 1.000 0.470 0.270 0.000 1.000 1.000 1.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 64 0 setvltmult X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 64 64 setvltmul Vt X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 64 128 setvltmu Vlt X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 X 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.0 V00 +-+-+-+-+-+-+-+- END OF PART 18 +-+-+-+-+-+-+-+-