-+-+-+-+-+-+-+-+ START OF PART 61 -+-+-+-+-+-+-+-+ X(picture)f(produced)h(by)g(the)g(traversal.)0 1602 y Fr(10.1)59 Xb(The)16 b(PHIGS)g(traversal)e(pr)o(ocess)0 1723 y Fq(In)f(PHIGS)g(the)g X(processes)i(of)e Fk(de\256ning)f Fq(the)h(model)g(and)g Fk(displaying)e XFq(a)j(view)f(of)g(it)f(on)h(a)h(workstation)d(are)j(quite)f(separate.)0 X1773 y(An)h(application)e(\256rst)i(constructs)f(the)h(model)f(and)h X(subsequently)f(noti\256es)g(PHIGS)h(which)g(part)f(to)h(interpret)e(for)i X(display)m(.)0 1823 y(The)d(process)h(of)e(interpretation)f(performed)h(by)h X(PHIGS)f(to)h(render)f(an)h(image)h(of)e(a)h(structure)g(network)e(is)i X(called)g Fk(traversal)p Fq(,)0 1873 y(and)i(is)h(shown)f(diagramatically)f X(in)h(Figure)g(10.1.)22 b(During)12 b(traversal)h(PHIGS)h(visits)e(each)i X(element)g(of)g(each)g(structure)f(in)0 1923 y(the)d(network,)g(applying)e X(modelling)h(transformations)g(and)h(attribute)f(speci\256cations)h(to)g X(generate)g(the)g(picture.)15 b(T)o(raversal)10 b(is)0 1972 Xy(conceptually)h(`60atomic'\320the)h(application)e(cannot)i(monitor)f(the)h X(particular)g(path)f(taken)i(through)d(a)j(structure)e(network)h(as)0 X2022 y(it)g(is)g(traversed,)h(nor)f(the)g(state)g(of)g(the)h(accumulated)g X(modelling)e(transformations)g(and)h(attributes.)17 b(T)m(o)c(determine)f X(exactly)0 2072 y(what)j(is)g(happening,)g(an)g(application)f(programmer)h X(is)g(forced)g(to)f(simulate)h(the)g(PHIGS)g(traversal)g(process)h(`60on)e X(paper)r(',)0 2122 y(which)d(for)g(anything)e(but)i(the)g(most)g(simple)g X(model)g(is)h(a)f(tedious)g(and)g(error)o(-prone)g(exercise.)0 X2201 y(Programming)e(with)f(PHIGS)i(is)f(often)g(not)g(straightforward.)k X(When)c(attempting)g(to)g(construct)f(anything)g(but)h(the)g(most)h(triv-)0 X2250 y(ial)h(structure)h(network)f(to)g(represent)h(an)g(application)f X(model,)h(it)f(soon)g(becomes)j(dif)o(\256cult)c(to)i(keep)g(track)g(of)f X(the)h(model.)17 b(A)0 2300 y(particular)9 b(problem)h(arises)h(from)f(the)g X(nature)g(of)g(the)g(traversal)h(process.)k(It)10 b(is)g(vital)f(to)h X(manipulate)g(modelling)e(transforma-)0 2350 y(tions)f(and)h(attributes)f X(correctly;)h(for)g(example,)h(incorrectly)e(speci\256ed)i(modelling)e X(transformations)f(can)j(lead)g(to)e(unexpected)0 2400 y(results)k(in)g(the) Vh X(displayed)f(picture\320and)f(more)i(often)f(than)h(not,)f(no)g(picture)g(at V) Xh(all.)k(Nevertheless,)d(these)f(observations)f(do)0 2450 y(not)g(denigrate) Vf X(the)i(fundamental)f(power)g(and)g(\257exibility)e(of)i(the)g(PHIGS)h(model. V) Xj(Instead,)d(they)f(point)f(to)h(the)g(necessity)h(of)0 2500 Xy(providing)d(more)j(helpful)e(interfaces)h(to)g(the)g(basic)h(functionality V) Xd(of)i(PHIGS.)0 2578 y(When)f(PHIGS)h(traverses)g(a)f(structure)g(network,)g X(it)f(records)i(the)f(current)g(values)g(of)g(primitive)f(attributes,)g X(modelling)g(trans-)0 2628 y(formations)j(and)i(other)f(quantities)f(in)h(a) Vh X(data)g(structure)f(called)g(the)h(`60T)o(raversal)g(State)f(List')g(\(TSL\) V.)i X(Since)f(the)f(TSL)h(only)0 2678 y(exists)d(while)g(traversal)h(is)g(active, V) Xg(and)g(traversal)g(is)f(an)h(atomic)g(process,)h(the)f(application)e(cannot V) Xh(access)j(and)e(inquire)e(the)0 2728 y(contents)h(of)g(the)g(TSL.)i(The)e X(traversal)h(process)g(is)f(de\256ned)g(as)h(follows:)912 2956 Xy(53)p eop X%%Page: 54 55 Xbop 0 -137 a Fq(PHIGS)11 b(T)m(oolkit)f(User)i(Manual)1235 Xb(PTK/100)425 -33 y X 16036234 18646798 657817 394690 31706808 36311531 startTexFig X425 -33 a X%%BeginDocument: trav.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 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 192 setvltmu Vlt X 0.000 0.000 0.000 1 0 setvltmult 0.000 0.000 0.000 1 1 setvltmult 0.000 0.0 V00 X 0.000 1 2 setvltmult 0.000 0.000 0.000 1 3 setvltmult 0.000 0.000 0.000 1 4 X setvltmult 0.000 0.000 0.000 1 5 setvltmult 0.000 0.000 0.000 1 6 setvltmul Vt X 0.000 0.000 0.000 1 7 setvltmult 0.000 0.000 0.000 1 8 setvltmult 0.000 0.0 V00 X 0.000 1 9 setvltmult 0.000 0.000 0.000 1 10 setvltmult 2 setlinewidth 1 X selcolorindex 718 827 955 1311 2 polyline 718 874 718 827 2 polyline 766 86 V2 X 718 827 2 polyline 1616 886 1297 1311 2 polyline 1604 933 1616 886 2 polyli Vne X 1569 909 1616 886 2 polyline 1470 1210 1470 1181 2 polyline 1470 1204 1466 V 1208 X 1462 1210 1456 1210 1452 1208 1447 1204 1445 1198 1445 1194 1447 1187 1452 V 1183 X 1456 1181 1462 1181 1466 1183 1470 1187 14 polyline 1489 1225 1489 1189 149 V1 X 1183 1496 1181 1500 1181 5 polyline 1483 1210 1498 1210 2 polyline 1514 122 V5 X 1514 1189 1516 1183 1521 1181 1525 1181 5 polyline 1508 1210 1523 1210 2 X polyline 1537 1210 1537 1181 2 polyline 1537 1198 1539 1204 1544 1208 1548 V 1210 X 1554 1210 5 polyline 1562 1225 1565 1223 1567 1225 1565 1227 1562 1225 5 X polyline 1565 1210 1565 1181 2 polyline 1581 1225 1581 1181 2 polyline 1581 X 1204 1585 1208 1590 1210 1596 1210 1600 1208 1604 1204 1606 1198 1606 1194 V 1604 X 1187 1600 1183 1596 1181 1590 1181 1585 1183 1581 1187 14 polyline 1621 121 V0 X 1621 1189 1623 1183 1627 1181 1634 1181 1638 1183 1644 1189 7 polyline 1644 X 1210 1644 1181 2 polyline 1663 1225 1663 1189 1665 1183 1669 1181 1673 1181 V 5 X polyline 1657 1210 1671 1210 2 polyline 1684 1198 1709 1198 1709 1202 1707 V 1206 X 1705 1208 1701 1210 1694 1210 1690 1208 1686 1204 1684 1198 1684 1194 1686 V 1187 X 1690 1183 1694 1181 1701 1181 1705 1183 1709 1187 17 polyline 1745 1204 174 V2 X 1208 1736 1210 1730 1210 1724 1208 1722 1204 1724 1200 1728 1198 1738 1196 V 1742 X 1194 1745 1189 1745 1187 1742 1183 1736 1181 1730 1181 1724 1183 1722 1187 V 17 X polyline 1646 2274 506 2274 506 2043 1646 2043 1646 2274 5 polyline 187 192 V5 X 217 1925 2 polyline 240 1925 287 1925 2 polyline 311 1925 358 1925 2 polyli Vne X 382 1925 429 1925 2 polyline 453 1925 500 1925 2 polyline 524 1925 571 1925 V 2 X polyline 594 1925 642 1925 2 polyline 665 1925 713 1925 2 polyline 736 1925 V 783 X 1925 2 polyline 807 1925 854 1925 2 polyline 878 1925 925 1925 2 polyline 9 V49 X 1925 996 1925 2 polyline 1020 1925 1067 1925 2 polyline 1091 1925 1138 1925 V 2 X polyline 1161 1925 1209 1925 2 polyline 1232 1925 1280 1925 2 polyline 1303 X 1925 1350 1925 2 polyline 1374 1925 1421 1925 2 polyline 1445 1925 1492 192 V5 2 X polyline 1516 1925 1563 1925 2 polyline 1587 1925 1634 1925 2 polyline 1657 X 1925 1705 1925 2 polyline 1728 1925 1776 1925 2 polyline 1799 1925 1846 192 V5 2 X polyline 1870 1925 1917 1925 2 polyline 1941 1925 1970 1925 2 polyline 187 V 1925 X 187 1925 2 polyline 187 1925 187 1925 2 polyline 195 1863 195 1819 2 polyli Vne X 195 1863 214 1863 220 1861 223 1859 225 1855 225 1848 223 1844 220 1842 214 X 1840 195 1840 10 polyline 239 1863 239 1819 2 polyline 269 1863 269 1819 2 X polyline 239 1842 269 1842 2 polyline 285 1863 285 1819 2 polyline 331 1852 V 329 X 1857 325 1861 321 1863 313 1863 308 1861 304 1857 302 1852 300 1846 300 183 V6 X 302 1829 304 1825 308 1821 313 1819 321 1819 325 1821 329 1825 331 1829 331 X 1836 19 polyline 321 1836 331 1836 2 polyline 373 1857 369 1861 363 1863 35 V4 X 1863 348 1861 344 1857 344 1852 346 1848 348 1846 352 1844 365 1840 369 183 V8 X 371 1836 373 1832 373 1825 369 1821 363 1819 354 1819 348 1821 344 1825 20 X polyline 749 2182 732 2138 2 polyline 749 2182 766 2138 2 polyline 738 2153 V 759 X 2153 2 polyline 776 2167 776 2123 2 polyline 776 2161 780 2165 785 2167 791 X 2167 795 2165 799 2161 801 2155 801 2150 799 2144 795 2140 791 2138 785 213 V8 +-+-+-+-+-+-+-+- END OF PART 61 +-+-+-+-+-+-+-+-