home *** CD-ROM | disk | FTP | other *** search
/ SGI Developer Toolbox 6.1 / SGI Developer Toolbox 6.1 - Disc 4.iso / public / rayshade / Doc / Guide / running.tex < prev    next >
LaTeX Document  |  1994-08-02  |  13.5 KB

open in: MacOS 8.1     |     Win98     |     DOS

browse contents    |     view JSON data     |     view as text


This file was processed as: LaTeX Document (document/latex).

ConfidenceProgramDetectionMatch TypeSupport
100% dexvert LaTeX Document (document/latex) magic Supported
1% dexvert Corel 10 Texture (image/corel10Texture) ext Unsupported
1% dexvert Croteam texture file (image/croteamTextureFile) ext Unsupported
1% dexvert Text File (text/txt) fallback Supported
100% file LaTeX document text default
99% file LaTeX document, ASCII text default
100% checkBytes Printable ASCII default
100% perlTextCheck Likely Text (Perl) default
100% siegfried fmt/281 LaTeX (Subdocument) default
100% detectItEasy Format: plain text[LF] default (weak)



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 5c 63 68 61 70 74 65 72 | 7b 52 75 6e 6e 69 6e 67 |\chapter|{Running|
|00000010| 20 52 61 79 73 68 61 64 | 65 7d 0a 0a 7b 5c 52 61 | Rayshad|e}..{\Ra|
|00000020| 79 73 68 61 64 65 7d 0a | 63 61 6e 20 74 61 6b 65 |yshade}.|can take|
|00000030| 20 61 6e 79 77 68 65 72 | 65 20 66 72 6f 6d 20 73 | anywher|e from s|
|00000040| 65 63 6f 6e 64 73 20 74 | 6f 20 77 65 65 6b 73 20 |econds t|o weeks |
|00000050| 74 6f 20 72 65 6e 64 65 | 72 20 61 6e 20 69 6d 61 |to rende|r an ima|
|00000060| 67 65 2e 20 20 54 68 65 | 20 65 78 61 63 74 0a 74 |ge. The| exact.t|
|00000070| 69 6d 65 20 72 65 71 75 | 69 72 65 64 20 69 73 20 |ime requ|ired is |
|00000080| 61 20 66 75 6e 63 74 69 | 6f 6e 20 6f 66 20 74 68 |a functi|on of th|
|00000090| 65 20 73 70 65 65 64 20 | 6f 66 20 74 68 65 0a 6d |e speed |of the.m|
|000000a0| 61 63 68 69 6e 65 28 73 | 29 20 6f 6e 20 77 68 69 |achine(s|) on whi|
|000000b0| 63 68 0a 79 6f 75 27 72 | 65 20 77 6f 72 6b 69 6e |ch.you'r|e workin|
|000000c0| 67 2c 20 74 68 65 20 63 | 6f 6d 70 6c 65 78 69 74 |g, the c|omplexit|
|000000d0| 79 20 6f 66 20 74 68 65 | 20 73 63 65 6e 65 2c 20 |y of the| scene, |
|000000e0| 61 6e 64 20 68 6f 77 20 | 60 60 67 6f 6f 64 27 27 |and how |``good''|
|000000f0| 20 79 6f 75 20 77 61 6e | 74 0a 74 68 65 20 66 69 | you wan|t.the fi|
|00000100| 6e 61 6c 20 69 6d 61 67 | 65 20 74 6f 20 62 65 2e |nal imag|e to be.|
|00000110| 20 20 5c 66 6f 6f 74 6e | 6f 74 65 7b 41 70 70 65 | \footn|ote{Appe|
|00000120| 6e 64 69 78 20 44 20 64 | 65 73 63 72 69 62 65 73 |ndix D d|escribes|
|00000130| 20 73 6f 6d 65 20 73 69 | 6d 70 6c 65 0a 77 61 79 | some si|mple.way|
|00000140| 73 20 74 6f 20 61 63 63 | 65 6c 65 72 61 74 65 20 |s to acc|elerate |
|00000150| 74 68 65 20 72 65 6e 64 | 65 72 69 6e 67 20 70 72 |the rend|ering pr|
|00000160| 6f 63 65 73 73 2e 7d 0a | 0a 43 72 65 61 74 69 6e |ocess.}.|.Creatin|
|00000170| 67 20 61 20 66 69 6e 69 | 73 68 65 64 20 72 61 79 |g a fini|shed ray|
|00000180| 2d 74 72 61 63 65 64 20 | 69 6d 61 67 65 20 69 73 |-traced |image is|
|00000190| 20 61 6e 20 69 74 65 72 | 61 74 69 76 65 20 70 72 | an iter|ative pr|
|000001a0| 6f 63 65 73 73 2e 20 20 | 55 73 75 61 6c 6c 79 2c |ocess. |Usually,|
|000001b0| 20 6d 61 6e 79 0a 74 65 | 73 74 20 72 65 6e 64 65 | many.te|st rende|
|000001c0| 72 69 6e 67 73 20 61 72 | 65 20 6d 61 64 65 20 61 |rings ar|e made a|
|000001d0| 74 20 6c 6f 77 20 72 65 | 73 6f 6c 75 74 69 6f 6e |t low re|solution|
|000001e0| 20 61 6e 64 20 77 69 74 | 68 0a 6e 6f 6e 2d 65 73 | and wit|h.non-es|
|000001f0| 73 65 6e 74 69 61 6c 20 | 66 65 61 74 75 72 65 73 |sential |features|
|00000200| 20 74 75 72 6e 65 64 20 | 6f 66 66 2e 20 20 41 66 | turned |off. Af|
|00000210| 74 65 72 20 65 61 63 68 | 20 74 65 73 74 20 69 6d |ter each| test im|
|00000220| 61 67 65 20 69 73 20 63 | 72 65 61 74 65 64 2c 0a |age is c|reated,.|
|00000230| 73 75 72 66 61 63 65 20 | 64 65 66 69 6e 69 74 69 |surface |definiti|
|00000240| 6f 6e 73 20 6d 69 67 68 | 74 20 62 65 20 6d 6f 64 |ons migh|t be mod|
|00000250| 69 66 69 65 64 2c 20 74 | 68 65 20 65 79 65 20 6f |ified, t|he eye o|
|00000260| 72 20 6c 6f 6f 6b 20 70 | 6f 73 69 74 69 6f 6e 73 |r look p|ositions|
|00000270| 20 6d 61 79 20 62 65 0a | 73 6c 69 67 68 74 6c 79 | may be.|slightly|
|00000280| 20 63 68 61 6e 67 65 64 | 2c 20 6f 72 20 74 68 65 | changed|, or the|
|00000290| 20 69 6e 74 65 6e 73 69 | 74 79 20 6f 66 20 61 20 | intensi|ty of a |
|000002a0| 6c 69 67 68 74 20 73 6f | 75 72 63 65 20 63 68 61 |light so|urce cha|
|000002b0| 6e 67 65 64 2e 0a 0a 54 | 68 69 73 20 63 68 61 70 |nged...T|his chap|
|000002c0| 74 65 72 20 64 65 73 63 | 72 69 62 65 73 20 74 68 |ter desc|ribes th|
|000002d0| 65 20 62 61 73 69 63 20 | 6f 70 65 72 61 74 69 6f |e basic |operatio|
|000002e0| 6e 20 6f 66 20 7b 5c 72 | 61 79 73 68 61 64 65 7d |n of {\r|ayshade}|
|000002f0| 20 61 6e 64 20 73 6f 6d | 65 20 6f 66 0a 74 68 65 | and som|e of.the|
|00000300| 20 6f 70 74 69 6f 6e 73 | 20 74 68 61 74 20 63 6f | options| that co|
|00000310| 6e 74 72 6f 6c 20 74 68 | 61 74 20 6f 70 65 72 61 |ntrol th|at opera|
|00000320| 74 69 6f 6e 2e 0a 53 65 | 74 74 69 6e 67 20 74 68 |tion..Se|tting th|
|00000330| 65 73 65 20 6f 70 74 69 | 6f 6e 73 20 70 72 6f 70 |ese opti|ons prop|
|00000340| 65 72 6c 79 20 63 61 6e | 20 67 72 65 61 74 6c 79 |erly can| greatly|
|00000350| 20 72 65 64 75 63 65 0a | 72 65 6e 64 65 72 69 6e | reduce.|renderin|
|00000360| 67 20 74 69 6d 65 2c 20 | 69 6d 70 72 6f 76 65 20 |g time, |improve |
|00000370| 74 68 65 20 71 75 61 6c | 69 74 79 20 6f 66 20 79 |the qual|ity of y|
|00000380| 6f 75 72 20 69 6d 61 67 | 65 73 2c 20 61 6e 64 20 |our imag|es, and |
|00000390| 6d 61 6b 65 20 79 6f 75 | 20 61 20 62 65 74 74 65 |make you| a bette|
|000003a0| 72 0a 70 65 72 73 6f 6e | 2e 0a 0a 7b 5c 52 61 79 |r.person|...{\Ray|
|000003b0| 73 68 61 64 65 7d 20 75 | 73 75 61 6c 6c 79 20 77 |shade} u|sually w|
|000003c0| 6f 72 6b 73 20 61 73 20 | 61 20 66 69 6c 74 65 72 |orks as |a filter|
|000003d0| 2c 20 72 65 61 64 69 6e | 67 20 61 20 64 65 73 63 |, readin|g a desc|
|000003e0| 72 69 70 74 69 6f 6e 20 | 66 72 6f 6d 0a 74 68 65 |ription |from.the|
|000003f0| 20 73 74 61 6e 64 61 72 | 64 20 69 6e 70 75 74 20 | standar|d input |
|00000400| 61 6e 64 20 77 72 69 74 | 69 6e 67 0a 61 6e 20 69 |and writ|ing.an i|
|00000410| 6d 61 67 65 20 66 69 6c | 65 20 74 6f 20 74 68 65 |mage fil|e to the|
|00000420| 20 73 74 61 6e 64 61 72 | 64 20 6f 75 74 70 75 74 | standar|d output|
|00000430| 2e 20 20 41 73 20 69 74 | 20 69 73 20 77 6f 72 6b |. As it| is work|
|00000440| 69 6e 67 2c 20 7b 5c 72 | 61 79 73 68 61 64 65 7d |ing, {\r|ayshade}|
|00000450| 20 72 65 70 6f 72 74 73 | 0a 6f 6e 20 74 68 65 20 | reports|.on the |
|00000460| 70 72 6f 67 72 65 73 73 | 20 6f 66 20 74 68 65 20 |progress| of the |
|00000470| 72 65 6e 64 65 72 69 6e | 67 20 62 79 20 77 72 69 |renderin|g by wri|
|00000480| 74 69 6e 67 20 6d 65 73 | 73 61 67 65 73 20 74 6f |ting mes|sages to|
|00000490| 20 74 68 65 20 73 74 61 | 6e 64 61 72 64 0a 65 72 | the sta|ndard.er|
|000004a0| 72 6f 72 2e 0a 0a 5c 73 | 65 63 74 69 6f 6e 7b 54 |ror...\s|ection{T|
|000004b0| 68 65 20 49 6e 70 75 74 | 20 46 69 6c 65 7d 0a 0a |he Input| File}..|
|000004c0| 54 68 65 20 73 63 65 6e | 65 20 64 65 73 63 72 69 |The scen|e descri|
|000004d0| 70 74 69 6f 6e 20 72 65 | 61 64 20 62 79 20 7b 5c |ption re|ad by {\|
|000004e0| 72 61 79 73 68 61 64 65 | 7d 20 63 6f 6e 73 69 73 |rayshade|} consis|
|000004f0| 74 73 20 6f 66 20 61 20 | 6e 75 6d 62 65 72 20 6f |ts of a |number o|
|00000500| 66 0a 6b 65 79 77 6f 72 | 64 73 2c 20 65 61 63 68 |f.keywor|ds, each|
|00000510| 20 66 6f 6c 6c 6f 77 65 | 64 20 62 79 20 61 20 73 | followe|d by a s|
|00000520| 65 74 20 6f 66 20 61 72 | 67 75 6d 65 6e 74 73 2e |et of ar|guments.|
|00000530| 20 20 54 68 65 73 65 20 | 6b 65 79 77 6f 72 64 73 | These |keywords|
|00000540| 20 63 61 6e 0a 62 65 20 | 74 68 6f 75 67 68 74 20 | can.be |thought |
|00000550| 6f 66 20 61 73 20 63 6f | 6d 6d 61 6e 64 73 20 74 |of as co|mmands t|
|00000560| 68 61 74 20 64 69 72 65 | 63 74 20 7b 5c 72 61 79 |hat dire|ct {\ray|
|00000570| 73 68 61 64 65 7d 20 74 | 6f 20 64 6f 20 76 61 72 |shade} t|o do var|
|00000580| 69 6f 75 73 20 74 68 69 | 6e 67 73 2c 0a 73 75 63 |ious thi|ngs,.suc|
|00000590| 68 20 61 73 20 63 72 65 | 61 74 65 20 6f 62 6a 65 |h as cre|ate obje|
|000005a0| 63 74 73 2c 20 73 65 74 | 20 74 68 65 20 65 79 65 |cts, set| the eye|
|000005b0| 27 73 20 70 6f 73 69 74 | 69 6f 6e 2c 20 61 6e 64 |'s posit|ion, and|
|000005c0| 20 63 68 61 6e 67 65 20 | 61 6e 20 6f 62 6a 65 63 | change |an objec|
|000005d0| 74 27 73 0a 61 70 70 65 | 61 72 61 6e 63 65 2e 0a |t's.appe|arance..|
|000005e0| 0a 4d 61 6e 79 20 6f 66 | 20 74 68 65 20 6b 65 79 |.Many of| the key|
|000005f0| 77 6f 72 64 73 20 68 61 | 76 65 20 72 65 6c 61 74 |words ha|ve relat|
|00000600| 65 64 20 63 6f 6d 6d 61 | 6e 64 2d 6c 69 6e 65 20 |ed comma|nd-line |
|00000610| 6f 70 74 69 6f 6e 73 20 | 66 6f 72 20 74 75 72 6e |options |for turn|
|00000620| 69 6e 67 0a 6f 6e 20 73 | 70 65 63 69 61 6c 20 66 |ing.on s|pecial f|
|00000630| 65 61 74 75 72 65 73 20 | 61 6e 64 20 73 65 74 74 |eatures |and sett|
|00000640| 69 6e 67 20 76 61 6c 75 | 65 73 2e 0a 54 68 65 73 |ing valu|es..Thes|
|00000650| 65 20 6f 70 74 69 6f 6e | 73 20 6f 76 65 72 72 69 |e option|s overri|
|00000660| 64 65 20 74 68 65 20 76 | 61 6c 75 65 73 20 67 69 |de the v|alues gi|
|00000670| 76 65 6e 20 69 6e 20 74 | 68 65 20 69 6e 70 75 74 |ven in t|he input|
|00000680| 20 66 69 6c 65 2c 0a 61 | 6e 64 20 61 72 65 20 65 | file,.a|nd are e|
|00000690| 78 70 6c 61 69 6e 65 64 | 20 69 6e 20 64 65 74 61 |xplained| in deta|
|000006a0| 69 6c 20 69 6e 20 41 70 | 70 65 6e 64 69 78 20 41 |il in Ap|pendix A|
|000006b0| 2e 0a 0a 7b 5c 52 61 79 | 73 68 61 64 65 7d 20 69 |...{\Ray|shade} i|
|000006c0| 73 20 60 60 63 61 73 65 | 20 73 65 6e 73 69 74 69 |s ``case| sensiti|
|000006d0| 76 65 2c 27 27 20 77 68 | 69 63 68 20 6d 65 61 6e |ve,'' wh|ich mean|
|000006e0| 73 20 74 68 61 74 20 74 | 79 70 69 6e 67 0a 7b 5c |s that t|yping.{\|
|000006f0| 74 74 20 53 50 48 45 52 | 45 7d 20 6f 72 20 7b 5c |tt SPHER|E} or {\|
|00000700| 74 74 20 53 70 68 65 72 | 65 7d 20 69 6e 73 74 65 |tt Spher|e} inste|
|00000710| 61 64 20 6f 66 20 7b 5c | 74 74 20 73 70 68 65 72 |ad of {\|tt spher|
|00000720| 65 7d 20 77 6f 6e 27 74 | 20 77 6f 72 6b 2e 0a 7b |e} won't| work..{|
|00000730| 5c 52 61 79 73 68 61 64 | 65 7d 20 6b 65 79 77 6f |\Rayshad|e} keywo|
|00000740| 72 64 73 20 61 72 65 20 | 61 6c 6c 20 6c 6f 77 65 |rds are |all lowe|
|00000750| 72 2d 63 61 73 65 2e 20 | 20 4d 61 6e 79 20 70 65 |r-case. | Many pe|
|00000760| 6f 70 6c 65 20 63 68 6f | 6f 73 65 20 74 6f 0a 63 |ople cho|ose to.c|
|00000770| 61 70 69 74 61 6c 69 7a | 65 20 74 68 65 20 66 69 |apitaliz|e the fi|
|00000780| 72 73 74 20 6c 65 74 74 | 65 72 20 6f 66 20 6e 61 |rst lett|er of na|
|00000790| 6d 65 73 20 74 68 61 74 | 20 74 68 65 79 20 67 69 |mes that| they gi|
|000007a0| 76 65 20 74 6f 20 6f 62 | 6a 65 63 74 73 0a 6f 72 |ve to ob|jects.or|
|000007b0| 20 73 75 72 66 61 63 65 | 73 20 69 6e 20 6f 72 64 | surface|s in ord|
|000007c0| 65 72 20 74 6f 20 6d 61 | 6b 65 20 74 68 65 6e 20 |er to ma|ke then |
|000007d0| 60 60 73 74 61 6e 64 20 | 6f 75 74 27 27 20 69 6e |``stand |out'' in|
|000007e0| 20 61 6e 20 69 6e 70 75 | 74 20 66 69 6c 65 2e 0a | an inpu|t file..|
|000007f0| 0a 4b 65 79 77 6f 72 64 | 73 2c 20 6e 75 6d 62 65 |.Keyword|s, numbe|
|00000800| 72 73 20 61 6e 64 20 73 | 74 72 69 6e 67 73 20 69 |rs and s|trings i|
|00000810| 6e 20 74 68 65 20 69 6e | 70 75 74 20 66 69 6c 65 |n the in|put file|
|00000820| 20 61 72 65 20 73 65 70 | 61 72 61 74 65 64 20 62 | are sep|arated b|
|00000830| 79 20 73 70 61 63 65 73 | 2c 0a 74 61 62 73 2c 20 |y spaces|,.tabs, |
|00000840| 6f 72 20 6e 65 77 20 6c | 69 6e 65 73 20 28 63 61 |or new l|ines (ca|
|00000850| 72 72 69 61 67 65 20 72 | 65 74 75 72 6e 73 29 2e |rriage r|eturns).|
|00000860| 20 20 54 68 65 73 65 20 | 60 60 77 68 69 74 65 73 | These |``whites|
|00000870| 70 61 63 65 27 27 20 63 | 68 61 72 61 63 74 65 72 |pace'' c|haracter|
|00000880| 73 0a 61 72 65 20 68 61 | 6e 64 6c 65 64 20 69 64 |s.are ha|ndled id|
|00000890| 65 6e 74 69 63 61 6c 6c | 79 20 62 79 20 7b 5c 72 |enticall|y by {\r|
|000008a0| 61 79 73 68 61 64 65 7d | 2c 20 77 68 69 63 68 20 |ayshade}|, which |
|000008b0| 6d 65 61 6e 73 20 74 68 | 61 74 20 79 6f 75 20 63 |means th|at you c|
|000008c0| 61 6e 20 73 65 70 61 72 | 61 74 65 0a 6b 65 79 77 |an separ|ate.keyw|
|000008d0| 6f 72 64 73 20 66 72 6f | 6d 20 6b 65 79 77 6f 72 |ords fro|m keywor|
|000008e0| 64 73 2c 20 6b 65 79 20 | 77 6f 72 64 73 20 66 72 |ds, key |words fr|
|000008f0| 6f 6d 20 61 72 67 75 6d | 65 6e 74 73 2c 20 61 6e |om argum|ents, an|
|00000900| 64 20 61 72 67 75 6d 65 | 6e 74 73 20 66 72 6f 6d |d argume|nts from|
|00000910| 0a 61 72 67 75 6d 65 6e | 74 73 20 75 73 69 6e 67 |.argumen|ts using|
|00000920| 20 61 6e 79 20 63 6f 6d | 62 69 6e 61 74 69 6f 6e | any com|bination|
|00000930| 20 6f 66 20 77 68 69 74 | 65 73 70 61 63 65 20 63 | of whit|espace c|
|00000940| 68 61 72 61 63 74 65 72 | 73 20 74 68 61 74 20 79 |haracter|s that y|
|00000950| 6f 75 20 63 68 6f 6f 73 | 65 2e 0a 0a 5c 62 65 67 |ou choos|e...\beg|
|00000960| 69 6e 7b 74 61 62 6c 65 | 7d 0a 5c 63 65 6e 74 65 |in{table|}.\cente|
|00000970| 72 69 6e 67 0a 5c 62 65 | 67 69 6e 7b 74 61 62 75 |ring.\be|gin{tabu|
|00000980| 6c 61 72 7d 7b 7c 63 7c | 63 7c 6c 7c 7d 5c 68 6c |lar}{|c||c|l|}\hl|
|00000990| 69 6e 65 5c 68 6c 69 6e | 65 0a 4f 70 65 72 61 74 |ine\hlin|e.Operat|
|000009a0| 6f 72 20 26 20 20 20 20 | 55 73 65 20 20 20 20 26 |or & |Use &|
|000009b0| 20 4f 70 65 72 61 74 69 | 6f 6e 20 5c 5c 20 5c 68 | Operati|on \\ \h|
|000009c0| 6c 69 6e 65 20 5c 68 6c | 69 6e 65 0a 5c 76 65 72 |line \hl|ine.\ver|
|000009d0| 62 2b 5e 2b 20 26 20 20 | 5c 76 65 72 62 21 61 20 |b+^+ & |\verb!a |
|000009e0| 5e 20 62 21 20 20 26 20 | 45 78 70 6f 6e 65 6e 74 |^ b! & |Exponent|
|000009f0| 69 61 74 69 6f 6e 20 5c | 5c 20 20 5c 68 6c 69 6e |iation \|\ \hlin|
|00000a00| 65 0a 5c 76 65 72 62 2b | 2d 2b 20 26 20 20 5c 76 |e.\verb+|-+ & \v|
|00000a10| 65 72 62 21 20 2d 61 20 | 20 21 20 20 26 20 4e 65 |erb! -a | ! & Ne|
|00000a20| 67 61 74 69 6f 6e 20 20 | 5c 5c 20 20 20 5c 68 6c |gation |\\ \hl|
|00000a30| 69 6e 65 0a 5c 76 65 72 | 62 2b 2a 2b 20 26 20 20 |ine.\ver|b+*+ & |
|00000a40| 5c 76 65 72 62 21 61 20 | 2a 20 62 21 20 20 26 20 |\verb!a |* b! & |
|00000a50| 4d 75 6c 74 69 70 6c 69 | 63 61 74 69 6f 6e 20 20 |Multipli|cation |
|00000a60| 5c 5c 20 20 5c 68 6c 69 | 6e 65 0a 5c 76 65 72 62 |\\ \hli|ne.\verb|
|00000a70| 2b 2f 2b 20 26 20 20 5c | 76 65 72 62 21 61 20 2f |+/+ & \|verb!a /|
|00000a80| 20 62 21 20 20 26 20 44 | 69 76 69 73 69 6f 6e 20 | b! & D|ivision |
|00000a90| 20 20 20 20 5c 5c 20 20 | 5c 68 6c 69 6e 65 0a 5c | \\ |\hline.\|
|00000aa0| 76 65 72 62 2b 25 2b 20 | 26 20 20 5c 76 65 72 62 |verb+%+ |& \verb|
|00000ab0| 21 61 20 25 20 62 21 20 | 20 26 20 52 65 6d 61 69 |!a % b! | & Remai|
|00000ac0| 6e 64 65 72 20 20 20 20 | 5c 5c 20 20 5c 68 6c 69 |nder |\\ \hli|
|00000ad0| 6e 65 0a 5c 76 65 72 62 | 2d 2b 2d 20 26 20 20 5c |ne.\verb|-+- & \|
|00000ae0| 76 65 72 62 21 61 20 2b | 20 62 21 20 20 26 20 41 |verb!a +| b! & A|
|00000af0| 64 64 69 74 69 6f 6e 20 | 20 20 20 20 5c 5c 20 5c |ddition | \\ \|
|00000b00| 68 6c 69 6e 65 0a 5c 76 | 65 72 62 2b 2d 2b 20 26 |hline.\v|erb+-+ &|
|00000b10| 20 20 5c 76 65 72 62 21 | 61 20 2d 20 62 21 20 20 | \verb!|a - b! |
|00000b20| 26 20 53 75 62 74 72 61 | 63 74 69 6f 6e 20 20 5c |& Subtra|ction \|
|00000b30| 5c 20 5c 68 6c 69 6e 65 | 20 5c 68 6c 69 6e 65 0a |\ \hline| \hline.|
|00000b40| 5c 65 6e 64 7b 74 61 62 | 75 6c 61 72 7d 0a 5c 63 |\end{tab|ular}.\c|
|00000b50| 61 70 74 69 6f 6e 7b 4f | 70 65 72 61 74 6f 72 73 |aption{O|perators|
|00000b60| 2c 20 69 6e 20 6f 72 64 | 65 72 20 6f 66 20 64 65 |, in ord|er of de|
|00000b70| 63 72 65 61 73 69 6e 67 | 20 70 72 65 63 65 64 65 |creasing| precede|
|00000b80| 6e 63 65 2e 7d 0a 5c 6c | 61 62 65 6c 7b 74 61 62 |nce.}.\l|abel{tab|
|00000b90| 3a 6f 70 65 72 61 74 6f | 72 73 7d 0a 5c 65 6e 64 |:operato|rs}.\end|
|00000ba0| 7b 74 61 62 6c 65 7d 0a | 0a 4e 75 6d 62 65 72 73 |{table}.|.Numbers|
|00000bb0| 20 6d 61 79 20 62 65 20 | 65 6e 74 65 72 65 64 20 | may be |entered |
|00000bc0| 64 69 72 65 63 74 6c 79 | 20 61 73 20 72 65 61 6c |directly| as real|
|00000bd0| 73 20 6f 72 20 61 73 20 | 70 61 72 65 6e 74 68 65 |s or as |parenthe|
|00000be0| 73 69 7a 65 64 20 65 78 | 70 72 65 73 73 69 6f 6e |sized ex|pression|
|00000bf0| 73 2e 0a 52 65 61 6c 73 | 20 6d 61 79 20 62 65 20 |s..Reals| may be |
|00000c00| 77 72 69 74 74 65 6e 20 | 69 6e 20 65 78 70 6f 6e |written |in expon|
|00000c10| 65 6e 74 69 61 6c 20 6e | 6f 74 61 74 69 6f 6e 20 |ential n|otation |
|00000c20| 69 66 20 79 6f 75 20 77 | 69 73 68 2c 20 61 6e 64 |if you w|ish, and|
|00000c30| 0a 69 6e 74 65 67 65 72 | 73 20 6d 61 79 20 62 65 |.integer|s may be|
|00000c40| 20 77 72 69 74 74 65 6e | 20 77 69 74 68 20 6f 72 | written| with or|
|00000c50| 20 77 69 74 68 6f 75 74 | 20 61 20 74 72 61 69 6c | without| a trail|
|00000c60| 69 6e 67 20 64 65 63 69 | 6d 61 6c 20 70 6f 69 6e |ing deci|mal poin|
|00000c70| 74 2e 0a 57 68 65 6e 20 | 61 6e 20 69 6e 74 65 67 |t..When |an integ|
|00000c80| 65 72 20 76 61 6c 75 65 | 20 69 73 20 63 61 6c 6c |er value| is call|
|00000c90| 65 64 20 66 6f 72 20 61 | 6e 64 20 61 20 72 65 61 |ed for a|nd a rea|
|00000ca0| 6c 20 69 73 20 67 69 76 | 65 6e 2c 0a 74 68 65 20 |l is giv|en,.the |
|00000cb0| 72 65 61 6c 20 76 61 6c | 75 65 20 69 73 20 74 72 |real val|ue is tr|
|00000cc0| 75 6e 63 61 74 65 64 20 | 61 6e 64 20 74 68 65 20 |uncated |and the |
|00000cd0| 72 65 73 75 6c 74 69 6e | 67 20 69 6e 74 65 67 65 |resultin|g intege|
|00000ce0| 72 20 69 73 20 75 73 65 | 64 2e 0a 54 61 62 6c 65 |r is use|d..Table|
|00000cf0| 20 5c 72 65 66 7b 74 61 | 62 3a 6f 70 65 72 61 74 | \ref{ta|b:operat|
|00000d00| 6f 72 73 7d 20 6c 69 73 | 74 73 20 74 68 65 20 61 |ors} lis|ts the a|
|00000d10| 76 61 69 6c 61 62 6c 65 | 20 6f 70 65 72 61 74 6f |vailable| operato|
|00000d20| 72 73 0a 61 76 61 69 6c | 61 62 6c 65 20 66 6f 72 |rs.avail|able for|
|00000d30| 20 75 73 65 20 69 6e 20 | 65 78 70 72 65 73 73 69 | use in |expressi|
|00000d40| 6f 6e 73 2c 20 69 6e 20 | 6f 72 64 65 72 20 6f 66 |ons, in |order of|
|00000d50| 20 64 65 63 72 65 61 73 | 69 6e 67 20 70 72 65 63 | decreas|ing prec|
|00000d60| 65 64 65 6e 63 65 2e 0a | 0a 54 68 65 20 75 70 73 |edence..|.The ups|
|00000d70| 68 6f 74 20 6f 66 20 61 | 6c 6c 20 74 68 69 73 20 |hot of a|ll this |
|00000d80| 69 73 20 74 68 61 74 20 | 74 68 65 20 73 74 72 69 |is that |the stri|
|00000d90| 6e 67 73 0a 7b 5c 74 74 | 20 34 32 7d 2c 20 7b 5c |ngs.{\tt| 42}, {\|
|00000da0| 74 74 20 34 32 2e 7d 2c | 0a 7b 5c 74 74 20 28 32 |tt 42.},|.{\tt (2|
|00000db0| 30 20 2b 20 32 32 29 7d | 2c 20 61 6e 64 20 7b 5c |0 + 22)}|, and {\|
|00000dc0| 74 74 20 28 37 5c 76 65 | 72 62 21 5e 21 32 20 2d |tt (7\ve|rb!^!2 -|
|00000dd0| 20 37 29 7d 20 6d 65 61 | 6e 20 74 68 65 20 73 61 | 7)} mea|n the sa|
|00000de0| 6d 65 20 74 68 69 6e 67 | 0a 74 6f 20 7b 5c 72 61 |me thing|.to {\ra|
|00000df0| 79 73 68 61 64 65 7d 2e | 0a 0a 56 61 72 69 61 62 |yshade}.|..Variab|
|00000e00| 6c 65 73 20 6d 61 79 20 | 61 6c 73 6f 20 62 65 20 |les may |also be |
|00000e10| 64 65 66 69 6e 65 64 20 | 61 6e 64 20 75 73 65 64 |defined |and used|
|00000e20| 20 69 6e 20 65 78 70 72 | 65 73 73 69 6f 6e 73 2e | in expr|essions.|
|00000e30| 20 20 53 65 76 65 72 61 | 6c 0a 62 75 69 6c 74 2d | Severa|l.built-|
|00000e40| 69 6e 20 66 75 6e 63 74 | 69 6f 6e 73 20 61 72 65 |in funct|ions are|
|00000e50| 20 61 6c 73 6f 20 70 72 | 6f 76 69 64 65 64 2e 20 | also pr|ovided. |
|00000e60| 20 53 65 65 20 41 70 70 | 65 6e 64 69 78 20 42 20 | See App|endix B |
|00000e70| 66 6f 72 20 66 75 72 74 | 68 65 72 20 64 65 74 61 |for furt|her deta|
|00000e80| 69 6c 73 2e 0a 0a 7b 5c | 52 61 79 73 68 61 64 65 |ils...{\|Rayshade|
|00000e90| 7d 20 77 69 6c 6c 20 61 | 75 74 6f 6d 61 74 69 63 |} will a|utomatic|
|00000ea0| 61 6c 6c 79 20 72 75 6e | 20 74 68 65 20 69 6e 70 |ally run| the inp|
|00000eb0| 75 74 20 69 74 20 72 65 | 63 65 69 76 65 73 0a 74 |ut it re|ceives.t|
|00000ec0| 68 72 6f 75 67 68 20 74 | 68 65 20 43 20 70 72 65 |hrough t|he C pre|
|00000ed0| 70 72 6f 63 65 73 73 6f | 72 20 69 66 20 69 74 20 |processo|r if it |
|00000ee0| 69 73 20 61 76 61 69 6c | 61 62 6c 65 2e 20 20 54 |is avail|able. T|
|00000ef0| 68 69 73 0a 61 6c 6c 6f | 77 73 20 79 6f 75 20 74 |his.allo|ws you t|
|00000f00| 6f 20 75 73 65 20 43 20 | 70 72 65 70 72 6f 63 65 |o use C |preproce|
|00000f10| 73 73 6f 72 20 64 69 72 | 65 63 74 69 76 65 73 2c |ssor dir|ectives,|
|00000f20| 20 73 75 63 68 20 61 73 | 20 7b 5c 74 74 20 5c 23 | such as| {\tt \#|
|00000f30| 69 6e 63 6c 75 64 65 7d | 2c 0a 7b 5c 74 74 20 5c |include}|,.{\tt \|
|00000f40| 23 64 65 66 69 6e 65 7d | 2c 20 61 6e 64 20 7b 5c |#define}|, and {\|
|00000f50| 74 74 20 5c 23 69 66 64 | 65 66 7d 20 77 68 65 6e |tt \#ifd|ef} when|
|00000f60| 20 64 65 73 69 67 6e 69 | 6e 67 20 79 6f 75 72 20 | designi|ng your |
|00000f70| 69 6e 70 75 74 20 66 69 | 6c 65 73 2e 0a 0a 43 6f |input fi|les...Co|
|00000f80| 6d 6d 65 6e 74 73 20 6d | 61 79 20 62 65 20 69 6e |mments m|ay be in|
|00000f90| 63 6c 75 64 65 64 20 69 | 6e 20 7b 5c 72 61 79 73 |cluded i|n {\rays|
|00000fa0| 68 61 64 65 7d 20 69 6e | 70 75 74 20 66 69 6c 65 |hade} in|put file|
|00000fb0| 73 20 62 79 20 65 6e 63 | 6c 6f 73 69 6e 67 0a 74 |s by enc|losing.t|
|00000fc0| 65 78 74 20 62 65 74 77 | 65 65 6e 20 74 68 65 20 |ext betw|een the |
|00000fd0| 73 74 72 69 6e 67 73 20 | 5c 76 65 72 62 21 2f 2a |strings |\verb!/*|
|00000fe0| 21 20 61 6e 64 20 5c 76 | 65 72 62 21 2a 2f 21 2c |! and \v|erb!*/!,|
|00000ff0| 20 61 73 20 69 6e 20 74 | 68 65 20 43 0a 70 72 6f | as in t|he C.pro|
|00001000| 67 72 61 6d 6d 69 6e 67 | 0a 6c 61 6e 67 75 61 67 |gramming|.languag|
|00001010| 65 2e 0a 0a 5c 73 65 63 | 74 69 6f 6e 7b 49 6d 61 |e...\sec|tion{Ima|
|00001020| 67 65 73 7d 0a 0a 54 68 | 65 20 65 6e 64 20 72 65 |ges}..Th|e end re|
|00001030| 73 75 6c 74 20 6f 66 20 | 72 75 6e 6e 69 6e 67 20 |sult of |running |
|00001040| 7b 5c 72 61 79 73 68 61 | 64 65 7d 20 69 73 20 61 |{\raysha|de} is a|
|00001050| 6e 20 69 6d 61 67 65 20 | 66 69 6c 65 2e 20 20 44 |n image |file. D|
|00001060| 65 70 65 6e 64 69 6e 67 | 20 75 70 6f 6e 0a 68 6f |epending| upon.ho|
|00001070| 77 20 69 74 20 77 61 73 | 20 69 6e 73 74 61 6c 6c |w it was| install|
|00001080| 65 64 2c 20 7b 5c 72 61 | 79 73 68 61 64 65 7d 20 |ed, {\ra|yshade} |
|00001090| 77 72 69 74 65 73 20 69 | 6d 61 67 65 73 20 69 6e |writes i|mages in|
|000010a0| 20 65 69 74 68 65 72 20 | 74 68 65 20 55 74 61 68 | either |the Utah|
|000010b0| 20 52 61 73 74 65 72 0a | 7b 5c 65 6d 20 52 4c 45 | Raster.|{\em RLE|
|000010c0| 7d 20 66 6f 72 6d 61 74 | 20 6f 72 20 61 20 67 65 |} format| or a ge|
|000010d0| 6e 65 72 69 63 20 62 75 | 74 20 65 61 73 69 6c 79 |neric bu|t easily|
|000010e0| 2d 6d 61 6e 69 70 75 6c | 61 74 65 64 20 7b 5c 65 |-manipul|ated {\e|
|000010f0| 6d 20 6d 74 76 7d 20 66 | 6f 72 6d 61 74 0a 75 73 |m mtv} f|ormat.us|
|00001100| 65 64 20 62 79 20 4d 61 | 72 6b 20 56 61 6e 64 65 |ed by Ma|rk Vande|
|00001110| 57 65 74 74 65 72 69 6e | 67 20 69 6e 20 68 69 73 |Wetterin|g in his|
|00001120| 20 7b 5c 65 6d 20 6d 74 | 76 7d 20 72 61 79 20 74 | {\em mt|v} ray t|
|00001130| 72 61 63 65 72 2e 20 20 | 54 68 65 20 7b 5c 65 6d |racer. |The {\em|
|00001140| 20 6d 74 76 7d 0a 66 6f | 72 6d 61 74 20 63 6f 6e | mtv}.fo|rmat con|
|00001150| 73 69 73 74 73 20 6f 66 | 20 61 20 68 65 61 64 65 |sists of| a heade|
|00001160| 72 20 67 69 76 69 6e 67 | 20 74 68 65 20 72 65 73 |r giving| the res|
|00001170| 6f 6c 75 74 69 6f 6e 20 | 6f 66 20 74 68 65 20 69 |olution |of the i|
|00001180| 6d 61 67 65 20 66 6f 6c | 6c 6f 77 65 64 0a 62 79 |mage fol|lowed.by|
|00001190| 20 69 6e 74 65 72 6c 65 | 61 76 65 64 20 72 65 64 | interle|aved red|
|000011a0| 2d 67 72 65 65 6e 2d 62 | 6c 75 65 20 76 61 6c 75 |-green-b|lue valu|
|000011b0| 65 73 20 66 6f 72 20 65 | 61 63 68 20 70 69 78 65 |es for e|ach pixe|
|000011c0| 6c 2e 20 20 54 68 65 20 | 7b 5c 65 6d 20 52 4c 45 |l. The |{\em RLE|
|000011d0| 7d 20 66 6f 72 6d 61 74 | 0a 73 75 70 70 6f 72 74 |} format|.support|
|000011e0| 73 20 61 6e 20 61 72 62 | 69 74 72 61 72 79 20 6e |s an arb|itrary n|
|000011f0| 75 6d 62 65 72 20 6f 66 | 20 63 6f 6c 6f 72 20 63 |umber of| color c|
|00001200| 68 61 6e 6e 65 6c 73 2c | 0a 61 6e 20 61 6c 70 68 |hannels,|.an alph|
|00001210| 61 20 63 68 61 6e 6e 65 | 6c 2c 20 63 6f 6d 6d 65 |a channe|l, comme|
|00001220| 6e 74 73 2c 20 61 20 68 | 69 73 74 6f 72 79 20 66 |nts, a h|istory f|
|00001230| 69 65 6c 64 2c 20 61 6e | 64 20 74 68 65 20 61 62 |ield, an|d the ab|
|00001240| 69 6c 69 74 79 0a 74 6f | 20 74 72 65 61 74 20 69 |ility.to| treat i|
|00001250| 6d 61 67 65 73 20 61 73 | 20 77 69 6e 64 6f 77 73 |mages as| windows|
|00001260| 20 69 6e 74 6f 20 61 20 | 6c 61 72 67 65 72 20 69 | into a |larger i|
|00001270| 6d 61 67 65 2e 20 20 41 | 73 20 61 20 72 65 73 75 |mage. A|s a resu|
|00001280| 6c 74 20 6f 66 20 74 68 | 69 73 0a 66 6c 65 78 69 |lt of th|is.flexi|
|00001290| 62 69 6c 69 74 79 2c 20 | 61 20 6e 75 6d 62 65 72 |bility, |a number|
|000012a0| 20 6f 66 20 7b 5c 72 61 | 79 73 68 61 64 65 7d 27 | of {\ra|yshade}'|
|000012b0| 73 20 66 65 61 74 75 72 | 65 73 0a 61 72 65 20 6e |s featur|es.are n|
|000012c0| 6f 74 0a 73 75 70 70 6f | 72 74 65 64 20 69 66 20 |ot.suppo|rted if |
|000012d0| 74 68 65 20 7b 5c 65 6d | 20 6d 74 76 7d 20 66 6f |the {\em| mtv} fo|
|000012e0| 72 6d 61 74 20 69 73 20 | 62 65 69 6e 67 20 75 73 |rmat is |being us|
|000012f0| 65 64 2e 20 59 6f 75 20 | 61 72 65 20 74 68 75 73 |ed. You |are thus|
|00001300| 20 73 74 72 6f 6e 67 6c | 79 0a 65 6e 63 6f 75 72 | strongl|y.encour|
|00001310| 61 67 65 64 20 74 6f 20 | 6f 62 74 61 69 6e 20 61 |aged to |obtain a|
|00001320| 20 63 6f 70 79 20 6f 66 | 20 74 68 65 20 55 74 61 | copy of| the Uta|
|00001330| 68 20 52 61 73 74 65 72 | 20 54 6f 6f 6c 6b 69 74 |h Raster| Toolkit|
|00001340| 2e 0a 0a 49 66 20 74 68 | 65 20 7b 5c 65 6d 20 6d |...If th|e {\em m|
|00001350| 74 76 7d 0a 66 6f 72 6d | 61 74 20 69 73 20 75 73 |tv}.form|at is us|
|00001360| 65 64 2c 20 74 68 65 20 | 69 6d 61 67 65 20 77 69 |ed, the |image wi|
|00001370| 6c 6c 20 28 61 6e 64 20 | 6d 75 73 74 29 20 63 6f |ll (and |must) co|
|00001380| 6e 73 69 73 74 20 6f 66 | 20 74 68 72 65 65 20 65 |nsist of| three e|
|00001390| 69 67 68 74 2d 62 69 74 | 0a 63 6f 6c 6f 72 20 63 |ight-bit|.color c|
|000013a0| 68 61 6e 6e 65 6c 73 2e | 0a 49 66 20 74 68 65 20 |hannels.|.If the |
|000013b0| 7b 5c 65 6d 20 52 4c 45 | 7d 20 66 6f 72 6d 61 74 |{\em RLE|} format|
|000013c0| 20 69 73 20 75 73 65 64 | 2c 20 74 68 65 20 69 6d | is used|, the im|
|000013d0| 61 67 65 20 66 69 6c 65 | 20 63 6f 6e 73 69 73 74 |age file| consist|
|000013e0| 73 20 6f 66 20 74 68 72 | 65 65 0a 65 69 67 68 74 |s of thr|ee.eight|
|000013f0| 2d 62 69 74 20 63 6f 6c | 6f 72 20 63 68 61 6e 6e |-bit col|or chann|
|00001400| 65 6c 73 20 70 6c 75 73 | 20 61 6e 20 65 69 67 68 |els plus| an eigh|
|00001410| 74 2d 62 69 74 20 61 6c | 70 68 61 20 63 68 61 6e |t-bit al|pha chan|
|00001420| 6e 65 6c 2e 20 20 7b 5c | 52 61 79 73 68 61 64 65 |nel. {\|Rayshade|
|00001430| 7d 0a 61 6c 73 6f 20 64 | 6f 63 75 6d 65 6e 74 73 |}.also d|ocuments|
|00001440| 20 69 6e 20 74 68 65 20 | 7b 5c 65 6d 20 52 4c 45 | in the |{\em RLE|
|00001450| 7d 20 68 65 61 64 65 72 | 20 74 68 65 20 63 6f 6d |} header| the com|
|00001460| 6d 61 6e 64 20 6c 69 6e | 65 20 61 6e 64 20 7b 5c |mand lin|e and {\|
|00001470| 65 6d 20 67 61 6d 6d 61 | 7d 0a 76 61 6c 75 65 20 |em gamma|}.value |
|00001480| 75 73 65 64 20 69 6e 20 | 63 72 65 61 74 69 6e 67 |used in |creating|
|00001490| 20 74 68 65 20 69 6d 61 | 67 65 2e 0a 0a 49 66 20 | the ima|ge...If |
|000014a0| 6d 6f 72 65 20 74 68 61 | 6e 20 6f 6e 65 20 66 72 |more tha|n one fr|
|000014b0| 61 6d 65 20 69 73 20 72 | 65 6e 64 65 72 65 64 2c |ame is r|endered,|
|000014c0| 20 74 68 65 20 72 65 73 | 75 6c 74 69 6e 67 20 69 | the res|ulting i|
|000014d0| 6d 61 67 65 73 20 61 72 | 65 20 61 70 70 65 6e 64 |mages ar|e append|
|000014e0| 65 64 0a 69 6e 20 74 75 | 72 6e 0a 74 6f 20 74 68 |ed.in tu|rn.to th|
|000014f0| 65 20 69 6d 61 67 65 20 | 66 69 6c 65 2e 20 20 54 |e image |file. T|
|00001500| 68 65 20 76 61 72 69 6f | 75 73 20 75 74 69 6c 69 |he vario|us utili|
|00001510| 74 69 65 73 20 70 72 6f | 76 69 64 65 64 20 62 79 |ties pro|vided by|
|00001520| 20 74 68 65 0a 55 74 61 | 68 20 52 61 73 74 65 72 | the.Uta|h Raster|
|00001530| 20 54 6f 6f 6c 6b 69 74 | 20 63 61 6e 20 62 65 20 | Toolkit| can be |
|00001540| 75 73 65 64 20 74 6f 20 | 6d 61 6e 69 70 75 6c 61 |used to |manipula|
|00001550| 74 65 20 74 68 65 20 72 | 65 73 75 6c 74 69 6e 67 |te the r|esulting|
|00001560| 20 60 60 6d 6f 76 69 65 | 27 27 0a 66 69 6c 65 73 | ``movie|''.files|
|00001570| 2e 0a 49 66 20 74 68 65 | 20 54 6f 6f 6c 6b 69 74 |..If the| Toolkit|
|00001580| 20 69 73 20 6e 6f 74 20 | 62 65 69 6e 67 20 75 73 | is not |being us|
|00001590| 65 64 2c 20 79 6f 75 20 | 77 69 6c 6c 20 70 72 6f |ed, you |will pro|
|000015a0| 62 61 62 6c 79 20 6e 65 | 65 64 20 74 6f 20 77 72 |bably ne|ed to wr|
|000015b0| 69 74 65 0a 75 74 69 6c | 69 74 79 20 70 72 6f 67 |ite.util|ity prog|
|000015c0| 72 61 6d 73 20 74 6f 20 | 68 61 6e 64 6c 65 20 74 |rams to |handle t|
|000015d0| 68 65 20 64 65 63 69 64 | 65 64 6c 79 20 6e 6f 6e |he decid|edly non|
|000015e0| 2d 73 74 61 6e 64 61 72 | 64 20 6d 75 6c 74 69 2d |-standar|d multi-|
|000015f0| 69 6d 61 67 65 20 7b 5c | 65 6d 20 6d 74 76 7d 0a |image {\|em mtv}.|
|00001600| 66 6f 72 6d 61 74 20 66 | 69 6c 65 73 2e 0a 0a 42 |format f|iles...B|
|00001610| 79 20 64 65 66 61 75 6c | 74 2c 20 7b 5c 72 61 79 |y defaul|t, {\ray|
|00001620| 73 68 61 64 65 7d 20 77 | 72 69 74 65 73 20 74 68 |shade} w|rites th|
|00001630| 65 20 63 6f 6d 70 75 74 | 65 64 20 69 6d 61 67 65 |e comput|ed image|
|00001640| 20 74 6f 20 74 68 65 20 | 73 74 61 6e 64 61 72 64 | to the |standard|
|00001650| 20 6f 75 74 70 75 74 2e | 0a 54 68 65 20 69 6d 61 | output.|.The ima|
|00001660| 67 65 20 66 69 6c 65 20 | 6d 61 79 20 62 65 20 77 |ge file |may be w|
|00001670| 72 69 74 74 65 6e 20 74 | 6f 20 61 20 66 69 6c 65 |ritten t|o a file|
|00001680| 20 69 6e 73 74 65 61 64 | 20 62 79 20 73 70 65 63 | instead| by spec|
|00001690| 69 66 79 69 6e 67 20 61 | 20 66 69 6c 65 20 6e 61 |ifying a| file na|
|000016a0| 6d 65 0a 69 6e 20 74 68 | 65 20 69 6e 70 75 74 20 |me.in th|e input |
|000016b0| 73 74 72 65 61 6d 2e 0a | 0a 5c 62 65 67 69 6e 7b |stream..|.\begin{|
|000016c0| 64 65 66 6b 65 79 7d 7b | 6f 75 74 66 69 6c 65 7d |defkey}{|outfile}|
|000016d0| 7b 7b 5c 65 6d 20 66 69 | 6c 65 6e 61 6d 65 7d 7d |{{\em fi|lename}}|
|000016e0| 0a 09 57 72 69 74 65 20 | 74 68 65 20 63 6f 6d 70 |..Write |the comp|
|000016f0| 75 74 65 64 20 69 6d 61 | 67 65 20 74 6f 20 74 68 |uted ima|ge to th|
|00001700| 65 20 6e 61 6d 65 64 20 | 66 69 6c 65 2e 0a 5c 65 |e named |file..\e|
|00001710| 6e 64 7b 64 65 66 6b 65 | 79 7d 0a 54 68 65 20 6f |nd{defke|y}.The o|
|00001720| 75 74 70 75 74 20 66 69 | 6c 65 20 6e 61 6d 65 20 |utput fi|le name |
|00001730| 6d 61 79 20 61 6c 73 6f | 20 62 65 20 73 70 65 63 |may also| be spec|
|00001740| 69 66 69 65 64 20 6f 6e | 20 74 68 65 20 63 6f 6d |ified on| the com|
|00001750| 6d 61 6e 64 20 6c 69 6e | 65 20 62 79 0a 75 73 69 |mand lin|e by.usi|
|00001760| 6e 67 20 74 68 65 20 7b | 5c 74 74 20 2d 4f 7d 20 |ng the {|\tt -O} |
|00001770| 6f 70 74 69 6f 6e 2e 0a | 0a 54 68 65 20 73 69 7a |option..|.The siz|
|00001780| 65 20 6f 66 20 74 68 65 | 20 6f 75 74 70 75 74 20 |e of the| output |
|00001790| 69 6d 61 67 65 20 69 73 | 20 6d 65 61 73 75 72 65 |image is| measure|
|000017a0| 64 20 69 6e 20 70 69 78 | 65 6c 73 2e 20 20 54 68 |d in pix|els. Th|
|000017b0| 65 20 7b 5c 65 6d 20 78 | 7d 20 73 69 7a 65 0a 69 |e {\em x|} size.i|
|000017c0| 73 20 74 68 65 20 6e 75 | 6d 62 65 72 20 6f 66 20 |s the nu|mber of |
|000017d0| 70 69 78 65 6c 73 20 6c | 65 66 74 2d 74 6f 2d 72 |pixels l|eft-to-r|
|000017e0| 69 67 68 74 2c 20 77 68 | 69 6c 65 20 74 68 65 20 |ight, wh|ile the |
|000017f0| 7b 5c 65 6d 20 79 7d 20 | 73 69 7a 65 20 69 73 0a |{\em y} |size is.|
|00001800| 74 68 65 20 6e 75 6d 62 | 65 72 20 6f 66 20 70 69 |the numb|er of pi|
|00001810| 78 65 6c 73 20 62 6f 74 | 74 6f 6d 2d 74 6f 2d 74 |xels bot|tom-to-t|
|00001820| 6f 70 2e 0a 0a 5c 62 65 | 67 69 6e 7b 64 65 66 6b |op...\be|gin{defk|
|00001830| 65 79 7d 7b 73 63 72 65 | 65 6e 7d 7b 7b 5c 65 6d |ey}{scre|en}{{\em|
|00001840| 20 78 73 69 7a 65 20 79 | 73 69 7a 65 7d 7d 0a 09 | xsize y|size}}..|
|00001850| 55 73 65 20 61 20 73 63 | 72 65 65 6e 20 7b 5c 65 |Use a sc|reen {\e|
|00001860| 6d 20 78 73 69 7a 65 7d | 20 70 69 78 65 6c 73 20 |m xsize}| pixels |
|00001870| 77 69 64 65 20 62 79 20 | 7b 5c 65 6d 20 79 73 69 |wide by |{\em ysi|
|00001880| 7a 65 7d 20 70 69 78 65 | 6c 73 20 68 69 67 68 2e |ze} pixe|ls high.|
|00001890| 0a 5c 65 6e 64 7b 64 65 | 66 6b 65 79 7d 0a 54 68 |.\end{de|fkey}.Th|
|000018a0| 65 20 73 63 72 65 65 6e | 20 73 69 7a 65 20 6d 61 |e screen| size ma|
|000018b0| 79 20 61 6c 73 6f 20 62 | 65 20 73 65 74 20 6f 6e |y also b|e set on|
|000018c0| 20 74 68 65 20 63 6f 6d | 6d 61 6e 64 20 6c 69 6e | the com|mand lin|
|000018d0| 65 20 74 68 72 6f 75 67 | 68 0a 74 68 65 20 7b 5c |e throug|h.the {\|
|000018e0| 74 74 20 2d 52 7d 20 6f | 70 74 69 6f 6e 2e 0a 54 |tt -R} o|ption..T|
|000018f0| 68 65 20 64 65 66 61 75 | 6c 74 0a 73 63 72 65 65 |he defau|lt.scree|
|00001900| 6e 20 73 69 7a 65 20 69 | 73 20 35 31 32 20 62 79 |n size i|s 512 by|
|00001910| 20 35 31 32 20 70 69 78 | 65 6c 73 2e 0a 0a 57 68 | 512 pix|els...Wh|
|00001920| 65 6e 20 72 65 6e 64 65 | 72 69 6e 67 20 61 6e 20 |en rende|ring an |
|00001930| 69 6d 61 67 65 2c 20 69 | 74 20 69 73 20 6f 66 74 |image, i|t is oft|
|00001940| 65 6e 20 61 64 76 61 6e | 74 61 67 65 6f 75 73 20 |en advan|tageous |
|00001950| 74 6f 20 73 70 6c 69 74 | 20 74 68 65 20 69 6d 61 |to split| the ima|
|00001960| 67 65 0a 69 6e 74 6f 20 | 61 20 6e 75 6d 62 65 72 |ge.into |a number|
|00001970| 20 6f 66 20 64 69 73 6a | 6f 69 6e 74 20 77 69 6e | of disj|oint win|
|00001980| 64 6f 77 73 2c 20 65 61 | 63 68 20 6f 66 20 77 68 |dows, ea|ch of wh|
|00001990| 69 63 68 20 69 73 20 72 | 65 6e 64 65 72 65 64 0a |ich is r|endered.|
|000019a0| 6f 6e 20 61 20 64 69 66 | 66 65 72 65 6e 74 20 6d |on a dif|ferent m|
|000019b0| 61 63 68 69 6e 65 2e 20 | 20 4f 6e 65 20 74 68 65 |achine. | One the|
|000019c0| 6e 20 63 6f 6d 62 69 6e | 65 73 20 74 68 65 20 69 |n combin|es the i|
|000019d0| 6d 61 67 65 73 20 63 6f | 72 72 65 73 70 6f 6e 64 |mages co|rrespond|
|000019e0| 69 6e 67 20 74 6f 0a 74 | 68 65 20 77 69 6e 64 6f |ing to.t|he windo|
|000019f0| 77 73 20 69 6e 74 6f 20 | 61 20 66 69 6e 61 6c 20 |ws into |a final |
|00001a00| 69 6d 61 67 65 2e 0a 0a | 5c 62 65 67 69 6e 7b 64 |image...|\begin{d|
|00001a10| 65 66 6b 65 79 7d 7b 77 | 69 6e 64 6f 77 7d 7b 7b |efkey}{w|indow}{{|
|00001a20| 5c 65 6d 20 6d 69 6e 78 | 20 6d 61 78 78 20 6d 69 |\em minx| maxx mi|
|00001a30| 6e 79 20 6d 61 78 79 7d | 7d 0a 09 52 65 6e 64 65 |ny maxy}|}..Rende|
|00001a40| 72 20 74 68 65 20 69 6d | 61 67 65 20 69 6e 20 74 |r the im|age in t|
|00001a50| 68 65 20 67 69 76 65 6e | 20 77 69 6e 64 6f 77 2e |he given| window.|
|00001a60| 0a 5c 65 6e 64 7b 64 65 | 66 6b 65 79 7d 0a 54 68 |.\end{de|fkey}.Th|
|00001a70| 65 20 77 69 6e 64 6f 77 | 20 6d 75 73 74 20 62 65 |e window| must be|
|00001a80| 20 70 72 6f 70 65 72 6c | 79 0a 63 6f 6e 74 61 69 | properl|y.contai|
|00001a90| 6e 65 64 20 77 69 74 68 | 69 6e 20 74 68 65 20 73 |ned with|in the s|
|00001aa0| 63 72 65 65 6e 2c 20 69 | 2e 65 2e 2c 20 7b 5c 65 |creen, i|.e., {\e|
|00001ab0| 6d 20 6d 69 6e 78 7d 20 | 61 6e 64 20 7b 5c 65 6d |m minx} |and {\em|
|00001ac0| 20 6d 69 6e 79 7d 20 6d | 75 73 74 0a 62 65 20 67 | miny} m|ust.be g|
|00001ad0| 72 65 61 74 65 72 20 74 | 68 61 6e 20 6f 72 20 65 |reater t|han or e|
|00001ae0| 71 75 61 6c 20 74 6f 20 | 7a 65 72 6f 2c 20 77 68 |qual to |zero, wh|
|00001af0| 69 6c 65 20 7b 5c 65 6d | 20 6d 61 78 78 7d 20 61 |ile {\em| maxx} a|
|00001b00| 6e 64 0a 7b 5c 65 6d 20 | 6d 61 78 79 7d 20 6d 75 |nd.{\em |maxy} mu|
|00001b10| 73 74 20 62 65 20 6c 65 | 73 73 20 74 68 61 6e 20 |st be le|ss than |
|00001b20| 7b 5c 65 6d 20 78 73 69 | 7a 65 7d 20 61 6e 64 20 |{\em xsi|ze} and |
|00001b30| 7b 5c 65 6d 20 79 73 69 | 7a 65 7d 2c 20 72 65 73 |{\em ysi|ze}, res|
|00001b40| 70 65 63 74 69 76 65 6c | 79 2e 0a 54 68 65 20 55 |pectivel|y..The U|
|00001b50| 74 61 68 20 52 61 73 74 | 65 72 20 74 6f 6f 6c 0a |tah Rast|er tool.|
|00001b60| 7b 5c 65 6d 20 72 6c 65 | 63 6f 6d 70 5c 2f 7d 20 |{\em rle|comp\/} |
|00001b70| 69 73 20 75 73 65 66 75 | 6c 20 66 6f 72 20 72 65 |is usefu|l for re|
|00001b80| 63 6f 6e 73 74 72 75 63 | 74 69 6e 67 20 74 68 65 |construc|ting the|
|00001b90| 20 66 75 6c 6c 20 69 6d | 61 67 65 20 66 72 6f 6d | full im|age from|
|00001ba0| 0a 73 75 62 2d 69 6d 61 | 67 65 73 2e 0a 42 79 20 |.sub-ima|ges..By |
|00001bb0| 64 65 66 61 75 6c 74 2c | 20 74 68 65 20 77 69 6e |default,| the win|
|00001bc0| 64 6f 77 0a 69 73 20 65 | 71 75 69 76 61 6c 65 6e |dow.is e|quivalen|
|00001bd0| 74 20 74 6f 20 74 68 65 | 20 65 6e 74 69 72 65 20 |t to the| entire |
|00001be0| 73 63 72 65 65 6e 2e 0a | 0a 49 74 20 69 73 20 61 |screen..|.It is a|
|00001bf0| 6c 73 6f 20 63 6f 6e 76 | 65 6e 69 65 6e 74 20 74 |lso conv|enient t|
|00001c00| 6f 20 62 65 20 61 62 6c | 65 20 74 6f 20 72 65 6e |o be abl|e to ren|
|00001c10| 64 65 72 20 61 20 73 6d | 61 6c 6c 20 70 6f 72 74 |der a sm|all port|
|00001c20| 69 6f 6e 0a 6f 66 20 74 | 68 65 20 77 69 6e 64 6f |ion.of t|he windo|
|00001c30| 77 20 62 79 20 73 70 65 | 63 69 66 79 69 6e 67 20 |w by spe|cifying |
|00001c40| 61 20 73 75 62 72 65 67 | 69 6f 6e 20 75 73 69 6e |a subreg|ion usin|
|00001c50| 67 20 6e 6f 72 6d 61 6c | 69 7a 65 64 20 63 6f 6f |g normal|ized coo|
|00001c60| 72 64 69 6e 61 74 65 73 | 2e 0a 0a 5c 62 65 67 69 |rdinates|...\begi|
|00001c70| 6e 7b 64 65 66 6b 65 79 | 7d 7b 63 72 6f 70 7d 7b |n{defkey|}{crop}{|
|00001c80| 7b 5c 65 6d 20 6c 65 66 | 74 20 72 69 67 68 74 20 |{\em lef|t right |
|00001c90| 62 6f 74 74 6f 6d 20 74 | 6f 70 7d 7d 0a 09 43 72 |bottom t|op}}..Cr|
|00001ca0| 6f 70 20 74 68 65 20 72 | 65 6e 64 65 72 69 6e 67 |op the r|endering|
|00001cb0| 20 77 69 6e 64 6f 77 2e | 0a 5c 65 6e 64 7b 64 65 | window.|.\end{de|
|00001cc0| 66 6b 65 79 7d 0a 54 68 | 65 20 72 65 6e 64 65 72 |fkey}.Th|e render|
|00001cd0| 69 6e 67 20 77 69 6e 64 | 6f 77 20 69 73 20 63 72 |ing wind|ow is cr|
|00001ce0| 6f 70 70 65 64 20 62 79 | 20 72 65 6e 64 65 72 69 |opped by| renderi|
|00001cf0| 6e 67 20 74 68 65 20 73 | 63 72 65 65 6e 0a 61 72 |ng the s|creen.ar|
|00001d00| 65 61 20 74 68 61 74 20 | 66 61 6c 6c 73 20 77 69 |ea that |falls wi|
|00001d10| 74 68 69 6e 20 24 6d 69 | 6e 78 20 2b 20 6c 65 66 |thin $mi|nx + lef|
|00001d20| 74 28 6d 61 78 78 20 2d | 20 6d 69 6e 78 29 24 20 |t(maxx -| minx)$ |
|00001d30| 61 6e 64 0a 24 6d 69 6e | 78 20 2b 20 72 69 67 68 |and.$min|x + righ|
|00001d40| 74 28 6d 61 78 78 20 2d | 20 6d 69 6e 78 29 24 20 |t(maxx -| minx)$ |
|00001d50| 69 6e 20 74 68 65 20 24 | 58 24 20 64 69 72 65 63 |in the $|X$ direc|
|00001d60| 74 69 6f 6e 2c 20 61 6e | 64 20 73 69 6d 69 6c 61 |tion, an|d simila|
|00001d70| 72 6c 79 0a 66 6f 72 20 | 74 68 65 20 24 59 24 20 |rly.for |the $Y$ |
|00001d80| 64 69 72 65 63 74 69 6f | 6e 2e 0a 7b 5c 65 6d 20 |directio|n..{\em |
|00001d90| 4c 65 66 74 7d 20 61 6e | 64 20 7b 5c 65 6d 20 62 |Left} an|d {\em b|
|00001da0| 6f 74 74 6f 6d 7d 20 6d | 75 73 74 20 62 65 20 67 |ottom} m|ust be g|
|00001db0| 72 65 61 74 65 72 20 74 | 68 61 6e 20 6f 72 20 65 |reater t|han or e|
|00001dc0| 71 75 61 6c 20 74 6f 20 | 7a 65 72 6f 2e 0a 7b 5c |qual to |zero..{\|
|00001dd0| 65 6d 20 52 69 67 68 74 | 7d 20 61 6e 64 20 7b 5c |em Right|} and {\|
|00001de0| 65 6d 20 74 6f 70 7d 20 | 6d 75 73 74 20 62 65 20 |em top} |must be |
|00001df0| 6c 65 73 73 20 74 68 61 | 6e 20 6f 72 20 65 71 75 |less tha|n or equ|
|00001e00| 61 6c 20 74 6f 20 6f 6e | 65 2e 0a 49 66 20 7b 5c |al to on|e..If {\|
|00001e10| 65 6d 20 6c 65 66 74 7d | 20 69 73 20 67 72 65 61 |em left}| is grea|
|00001e20| 74 65 72 20 74 68 61 6e | 20 7b 5c 65 6d 20 72 69 |ter than| {\em ri|
|00001e30| 67 68 74 7d 2c 20 74 68 | 65 20 74 77 6f 20 76 61 |ght}, th|e two va|
|00001e40| 6c 75 65 73 20 61 72 65 | 0a 73 77 61 70 70 65 64 |lues are|.swapped|
|00001e50| 2c 20 61 6e 64 20 73 69 | 6d 69 6c 61 72 6c 79 20 |, and si|milarly |
|00001e60| 66 6f 72 20 7b 5c 65 6d | 20 62 6f 74 74 6f 6d 7d |for {\em| bottom}|
|00001e70| 20 61 6e 64 20 7b 5c 65 | 6d 20 74 6f 70 7d 2e 0a | and {\e|m top}..|
|00001e80| 0a 7b 5c 65 6d 20 47 61 | 6d 6d 61 20 63 6f 72 72 |.{\em Ga|mma corr|
|00001e90| 65 63 74 69 6f 6e 7d 20 | 6d 61 79 20 61 6c 73 6f |ection} |may also|
|00001ea0| 20 62 65 20 61 70 70 6c | 69 65 64 20 74 6f 20 74 | be appl|ied to t|
|00001eb0| 68 65 20 74 68 72 65 65 | 20 6f 75 74 70 75 74 20 |he three| output |
|00001ec0| 63 6f 6c 6f 72 0a 63 68 | 61 6e 6e 65 6c 73 2e 20 |color.ch|annels. |
|00001ed0| 20 53 65 65 20 41 70 70 | 65 6e 64 69 78 20 41 20 | See App|endix A |
|00001ee0| 66 6f 72 20 6d 6f 72 65 | 20 64 65 74 61 69 6c 73 |for more| details|
|00001ef0| 2e 0a 0a 5c 73 65 63 74 | 69 6f 6e 7b 53 74 61 74 |...\sect|ion{Stat|
|00001f00| 69 73 74 69 63 73 20 52 | 65 70 6f 72 74 69 6e 67 |istics R|eporting|
|00001f10| 7d 0a 0a 41 73 20 69 74 | 20 69 73 20 77 6f 72 6b |}..As it| is work|
|00001f20| 69 6e 67 2c 20 7b 5c 72 | 61 79 73 68 61 64 65 7d |ing, {\r|ayshade}|
|00001f30| 20 69 6e 66 6f 72 6d 73 | 20 79 6f 75 20 6f 66 20 | informs| you of |
|00001f40| 69 74 73 20 70 72 6f 67 | 72 65 73 73 20 62 79 20 |its prog|ress by |
|00001f50| 77 72 69 74 69 6e 67 0a | 6d 65 73 73 61 67 65 73 |writing.|messages|
|00001f60| 20 74 6f 20 61 20 60 60 | 72 65 70 6f 72 74 20 66 | to a ``|report f|
|00001f70| 69 6c 65 27 27 2e 20 20 | 42 79 20 64 65 66 61 75 |ile''. |By defau|
|00001f80| 6c 74 2c 20 74 68 65 20 | 72 65 70 6f 72 74 20 66 |lt, the |report f|
|00001f90| 69 6c 65 20 69 73 20 74 | 68 65 0a 73 74 61 6e 64 |ile is t|he.stand|
|00001fa0| 61 72 64 20 65 72 72 6f | 72 2e 20 20 54 68 65 20 |ard erro|r. The |
|00001fb0| 72 65 70 6f 72 74 20 69 | 74 73 65 6c 66 20 63 6f |report i|tself co|
|00001fc0| 6e 73 69 73 74 73 20 6f | 66 20 61 20 6e 75 6d 62 |nsists o|f a numb|
|00001fd0| 65 72 20 6f 66 0a 70 72 | 6f 67 72 65 73 73 20 72 |er of.pr|ogress r|
|00001fe0| 65 70 6f 72 74 20 6c 69 | 6e 65 73 20 63 6f 6e 73 |eport li|nes cons|
|00001ff0| 69 73 74 69 6e 67 20 6f | 66 20 74 68 65 20 6e 75 |isting o|f the nu|
|00002000| 6d 62 65 72 20 6f 66 20 | 65 79 65 20 72 61 79 73 |mber of |eye rays|
|00002010| 20 74 72 61 63 65 64 2c | 0a 74 68 65 20 74 6f 74 | traced,|.the tot|
|00002020| 61 6c 20 65 6c 61 70 73 | 65 64 20 74 69 6d 65 2c |al elaps|ed time,|
|00002030| 20 61 6e 64 20 74 68 65 | 20 65 6c 61 70 73 65 64 | and the| elapsed|
|00002040| 20 74 69 6d 65 20 73 69 | 6e 63 65 20 74 68 65 20 | time si|nce the |
|00002050| 6c 61 73 74 20 70 72 6f | 67 72 65 73 73 20 72 65 |last pro|gress re|
|00002060| 70 6f 72 74 2e 0a 54 68 | 65 20 65 6e 64 20 6f 66 |port..Th|e end of|
|00002070| 20 74 68 65 20 72 65 70 | 6f 72 74 20 63 6f 6e 74 | the rep|ort cont|
|00002080| 61 69 6e 73 20 64 65 74 | 61 69 6c 65 64 20 73 74 |ains det|ailed st|
|00002090| 61 74 69 73 74 69 63 73 | 20 61 62 6f 75 74 20 69 |atistics| about i|
|000020a0| 6e 74 65 72 73 65 63 74 | 69 6f 6e 0a 74 65 73 74 |ntersect|ion.test|
|000020b0| 73 20 70 65 72 66 6f 72 | 6d 65 64 2c 20 74 68 65 |s perfor|med, the|
|000020c0| 20 6e 75 6d 62 65 72 20 | 6f 66 20 72 61 79 73 20 | number |of rays |
|000020d0| 74 72 61 63 65 64 2c 20 | 61 6e 64 20 74 68 65 20 |traced, |and the |
|000020e0| 6c 69 6b 65 2e 0a 0a 5c | 62 65 67 69 6e 7b 64 65 |like...\|begin{de|
|000020f0| 66 6b 65 79 7d 7b 72 65 | 70 6f 72 74 7d 7b 5b 7b |fkey}{re|port}{[{|
|00002100| 5c 74 74 20 76 65 72 62 | 6f 73 65 7d 5d 20 5b 7b |\tt verb|ose}] [{|
|00002110| 5c 74 74 20 71 75 69 65 | 74 7d 5d 20 5b 7b 5c 65 |\tt quie|t}] [{\e|
|00002120| 6d 20 66 72 65 71 7d 5d | 20 5b 7b 5c 65 6d 20 66 |m freq}]| [{\em f|
|00002130| 69 6c 65 7d 5d 7d 0a 09 | 53 70 65 63 69 66 79 20 |ile}]}..|Specify |
|00002140| 74 68 65 20 6b 69 6e 64 | 20 6f 66 0a 09 69 6e 66 |the kind| of..inf|
|00002150| 6f 72 6d 61 74 69 6f 6e | 20 69 6e 63 6c 75 64 65 |ormation| include|
|00002160| 64 20 69 6e 20 74 68 65 | 20 72 65 70 6f 72 74 20 |d in the| report |
|00002170| 61 6e 64 20 74 6f 20 77 | 68 69 63 68 0a 09 66 69 |and to w|hich..fi|
|00002180| 6c 65 20 69 74 20 73 68 | 6f 75 6c 64 20 62 65 20 |le it sh|ould be |
|00002190| 77 72 69 74 74 65 6e 2e | 0a 09 49 66 20 7b 5c 74 |written.|..If {\t|
|000021a0| 74 20 76 65 72 62 6f 73 | 65 7d 20 69 73 20 73 70 |t verbos|e} is sp|
|000021b0| 65 63 69 66 69 65 64 2c | 20 74 68 65 0a 09 72 65 |ecified,| the..re|
|000021c0| 70 6f 72 74 20 77 69 6c | 6c 20 61 6c 73 6f 20 69 |port wil|l also i|
|000021d0| 6e 63 6c 75 64 65 20 61 | 20 6c 69 73 74 69 6e 67 |nclude a| listing|
|000021e0| 20 6f 66 20 74 68 65 20 | 6f 70 74 69 6f 6e 73 20 | of the |options |
|000021f0| 73 65 6c 65 63 74 65 64 | 2c 0a 09 74 68 65 20 0a |selected|,..the .|
|00002200| 09 62 6f 75 6e 64 69 6e | 67 20 76 6f 6c 75 6d 65 |.boundin|g volume|
|00002210| 73 20 6f 66 20 65 61 63 | 68 20 61 67 67 72 65 67 |s of eac|h aggreg|
|00002220| 61 74 65 2c 0a 09 61 6e | 64 20 74 68 65 20 74 6f |ate,..an|d the to|
|00002230| 74 61 6c 20 6e 75 6d 62 | 65 72 20 6f 66 20 70 72 |tal numb|er of pr|
|00002240| 69 6d 69 74 69 76 65 73 | 20 69 6e 20 65 61 63 68 |imitives| in each|
|00002250| 20 61 67 67 72 65 67 61 | 74 65 2e 0a 09 7b 5c 74 | aggrega|te...{\t|
|00002260| 74 20 71 75 69 65 74 7d | 20 63 61 75 73 65 73 20 |t quiet}| causes |
|00002270| 77 61 72 6e 69 6e 67 0a | 09 6d 65 73 73 61 67 65 |warning.|.message|
|00002280| 73 20 74 6f 20 62 65 20 | 73 75 70 70 72 65 73 73 |s to be |suppress|
|00002290| 65 64 2e 20 20 7b 5c 65 | 6d 20 66 72 65 71 7d 20 |ed. {\e|m freq} |
|000022a0| 73 70 65 63 69 66 69 65 | 73 20 74 68 65 20 66 72 |specifie|s the fr|
|000022b0| 65 71 75 65 6e 63 79 2c | 0a 09 69 6e 20 73 63 61 |equency,|..in sca|
|000022c0| 6e 6c 69 6e 65 73 20 72 | 65 6e 64 65 72 65 64 2c |nlines r|endered,|
|000022d0| 20 74 68 61 74 20 70 72 | 6f 67 72 65 73 73 20 72 | that pr|ogress r|
|000022e0| 65 70 6f 72 74 73 20 61 | 72 65 20 6d 61 64 65 2e |eports a|re made.|
|000022f0| 0a 09 49 66 20 67 69 76 | 65 6e 2c 20 7b 5c 65 6d |..If giv|en, {\em|
|00002300| 20 66 69 6c 65 7d 20 6e | 61 6d 65 73 20 61 20 66 | file} n|ames a f|
|00002310| 69 6c 65 20 74 6f 20 77 | 68 69 63 68 20 74 68 65 |ile to w|hich the|
|00002320| 20 72 65 70 6f 72 74 0a | 09 77 69 6c 6c 20 62 65 | report.|.will be|
|00002330| 20 77 72 69 74 74 65 6e | 2e 0a 5c 65 6e 64 7b 64 | written|..\end{d|
|00002340| 65 66 6b 65 79 7d 0a 42 | 79 20 64 65 66 61 75 6c |efkey}.B|y defaul|
|00002350| 74 2c 20 61 20 6e 6f 6e | 2d 76 65 72 62 6f 73 65 |t, a non|-verbose|
|00002360| 2c 20 6e 6f 6e 2d 71 75 | 69 65 74 20 72 65 70 6f |, non-qu|iet repo|
|00002370| 72 74 20 69 73 20 0a 77 | 72 69 74 74 65 6e 20 74 |rt is .w|ritten t|
|00002380| 6f 20 74 68 65 20 73 74 | 61 6e 64 61 72 64 20 65 |o the st|andard e|
|00002390| 72 72 6f 72 20 6f 6e 63 | 65 20 65 76 65 72 79 20 |rror onc|e every |
|000023a0| 31 30 20 6c 69 6e 65 73 | 2e 0a 54 68 65 20 7b 5c |10 lines|..The {\|
|000023b0| 74 74 20 2d 56 7d 20 6f | 70 74 69 6f 6e 20 6d 61 |tt -V} o|ption ma|
|000023c0| 79 20 61 6c 73 6f 20 62 | 65 20 75 73 65 64 20 74 |y also b|e used t|
|000023d0| 6f 20 64 69 72 65 63 74 | 20 74 68 65 20 72 65 70 |o direct| the rep|
|000023e0| 6f 72 74 20 74 6f 20 61 | 20 6e 61 6d 65 64 20 66 |ort to a| named f|
|000023f0| 69 6c 65 2e 0a 0a 5c 73 | 65 63 74 69 6f 6e 7b 41 |ile...\s|ection{A|
|00002400| 6e 74 69 61 6c 69 61 73 | 69 6e 67 7d 0a 0a 47 69 |ntialias|ing}..Gi|
|00002410| 76 65 6e 20 61 20 73 63 | 72 65 65 6e 20 6f 66 20 |ven a sc|reen of |
|00002420| 61 20 66 69 78 65 64 20 | 73 69 7a 65 2c 20 63 72 |a fixed |size, cr|
|00002430| 65 61 74 69 6e 67 20 61 | 6e 20 69 6d 61 67 65 20 |eating a|n image |
|00002440| 69 73 20 61 63 63 6f 6d | 70 6c 69 73 68 65 64 20 |is accom|plished |
|00002450| 62 79 0a 73 61 6d 70 6c | 69 6e 67 20 65 61 63 68 |by.sampl|ing each|
|00002460| 20 70 69 78 65 6c 20 6f | 6e 65 20 6f 72 20 6d 6f | pixel o|ne or mo|
|00002470| 72 65 20 74 69 6d 65 73 | 20 69 6e 20 6f 72 64 65 |re times| in orde|
|00002480| 72 20 74 6f 20 64 65 74 | 65 72 6d 69 6e 65 20 77 |r to det|ermine w|
|00002490| 68 61 74 20 63 61 6e 0a | 62 65 20 73 65 65 6e 20 |hat can.|be seen |
|000024a0| 60 60 74 68 72 6f 75 67 | 68 27 27 20 74 68 61 74 |``throug|h'' that|
|000024b0| 20 70 69 78 65 6c 20 62 | 79 20 74 68 65 20 63 61 | pixel b|y the ca|
|000024c0| 6d 65 72 61 2e 20 20 41 | 20 70 69 78 65 6c 20 74 |mera. A| pixel t|
|000024d0| 68 75 73 20 63 6f 76 65 | 72 73 0a 61 20 73 71 75 |hus cove|rs.a squ|
|000024e0| 61 72 65 20 61 72 65 61 | 20 6f 66 20 74 68 65 20 |are area| of the |
|000024f0| 69 6d 61 67 65 20 70 6c | 61 6e 65 2c 20 6e 6f 74 |image pl|ane, not|
|00002500| 20 6a 75 73 74 20 61 20 | 73 69 6e 67 6c 65 20 70 | just a |single p|
|00002510| 6f 69 6e 74 2e 0a 0a 49 | 66 20 61 20 70 69 78 65 |oint...I|f a pixe|
|00002520| 6c 20 69 73 20 6e 6f 74 | 20 73 61 6d 70 6c 65 64 |l is not| sampled|
|00002530| 20 61 74 20 74 68 65 20 | 70 72 6f 70 65 72 20 72 | at the |proper r|
|00002540| 61 74 65 2c 20 61 6c 69 | 61 73 69 6e 67 20 77 69 |ate, ali|asing wi|
|00002550| 6c 6c 20 72 65 73 75 6c | 74 2e 0a 41 6c 69 61 73 |ll resul|t..Alias|
|00002560| 69 6e 67 20 75 73 75 61 | 6c 6c 79 20 61 70 70 65 |ing usua|lly appe|
|00002570| 61 72 73 20 61 73 20 60 | 60 6a 61 67 67 69 65 73 |ars as `|`jaggies|
|00002580| 27 27 20 6f 72 20 60 60 | 73 74 61 69 72 20 73 74 |'' or ``|stair st|
|00002590| 65 70 73 27 27 20 69 6e | 20 74 68 65 20 69 6d 61 |eps'' in| the ima|
|000025a0| 67 65 2e 0a 49 6e 20 6f | 72 64 65 72 20 74 6f 20 |ge..In o|rder to |
|000025b0| 72 65 64 75 63 65 20 74 | 68 65 73 65 20 61 6e 64 |reduce t|hese and|
|000025c0| 20 6f 74 68 65 72 20 61 | 72 74 69 66 61 63 74 73 | other a|rtifacts|
|000025d0| 2c 20 7b 5c 72 61 79 73 | 68 61 64 65 7d 20 70 72 |, {\rays|hade} pr|
|000025e0| 6f 76 69 64 65 73 0a 61 | 6e 20 61 64 61 70 74 69 |ovides.a|n adapti|
|000025f0| 76 65 20 6a 69 74 74 65 | 72 65 64 20 61 6e 74 69 |ve jitte|red anti|
|00002600| 61 6c 69 61 73 69 6e 67 | 20 73 63 68 65 6d 65 20 |aliasing| scheme |
|00002610| 74 68 61 74 20 61 74 74 | 65 6d 70 74 73 20 74 6f |that att|empts to|
|00002620| 20 64 65 74 65 63 74 20 | 77 68 65 72 65 0a 69 6e | detect |where.in|
|00002630| 63 72 65 61 73 65 64 20 | 73 61 6d 70 6c 69 6e 67 |creased |sampling|
|00002640| 20 72 61 74 65 73 20 61 | 72 65 20 6e 65 65 64 65 | rates a|re neede|
|00002650| 64 2e 0a 49 6e 20 6a 69 | 74 74 65 72 65 64 20 73 |d..In ji|ttered s|
|00002660| 61 6d 70 6c 69 6e 67 2c | 20 74 68 65 20 6c 6f 63 |ampling,| the loc|
|00002670| 61 74 69 6f 6e 20 61 74 | 20 77 68 69 63 68 20 61 |ation at| which a|
|00002680| 20 73 61 6d 70 6c 65 20 | 69 73 20 74 61 6b 65 6e | sample |is taken|
|00002690| 20 69 73 0a 70 65 72 74 | 75 72 62 65 64 20 62 79 | is.pert|urbed by|
|000026a0| 20 61 20 72 61 6e 64 6f | 6d 20 61 6d 6f 75 6e 74 | a rando|m amount|
|000026b0| 2e 20 20 54 68 69 73 20 | 70 65 72 74 75 72 62 61 |. This |perturba|
|000026c0| 74 69 6f 6e 20 72 65 64 | 75 63 65 73 20 61 6c 69 |tion red|uces ali|
|000026d0| 61 73 69 6e 67 0a 62 75 | 74 20 61 64 64 73 20 6e |asing.bu|t adds n|
|000026e0| 6f 69 73 65 20 74 6f 20 | 74 68 65 20 69 6d 61 67 |oise to |the imag|
|000026f0| 65 2e 20 20 41 70 70 65 | 6e 64 69 78 20 42 20 64 |e. Appe|ndix B d|
|00002700| 65 73 63 72 69 62 65 73 | 20 68 6f 77 20 6a 69 74 |escribes| how jit|
|00002710| 74 65 72 65 64 0a 74 69 | 6d 65 20 73 61 6d 70 6c |tered.ti|me sampl|
|00002720| 69 6e 67 20 69 73 20 69 | 6d 70 6c 65 6d 65 6e 74 |ing is i|mplement|
|00002730| 65 64 20 69 6e 20 7b 5c | 72 61 79 73 68 61 64 65 |ed in {\|rayshade|
|00002740| 7d 2e 0a 0a 54 68 65 20 | 61 64 61 70 74 69 76 65 |}...The |adaptive|
|00002750| 20 73 61 6d 70 6c 69 6e | 67 20 73 63 68 65 6d 65 | samplin|g scheme|
|00002760| 20 69 6d 70 6c 65 6d 65 | 6e 74 65 64 20 69 6e 20 | impleme|nted in |
|00002770| 7b 5c 72 61 79 73 68 61 | 64 65 7d 20 62 65 67 69 |{\raysha|de} begi|
|00002780| 6e 73 0a 62 79 20 73 61 | 6d 70 6c 69 6e 67 20 65 |ns.by sa|mpling e|
|00002790| 61 63 68 20 70 69 78 65 | 6c 20 6f 6e 20 74 68 65 |ach pixe|l on the|
|000027a0| 20 63 75 72 72 65 6e 74 | 20 73 63 61 6e 6c 69 6e | current| scanlin|
|000027b0| 65 20 6f 6e 63 65 2e 0a | 46 6f 72 20 65 61 63 68 |e once..|For each|
|000027c0| 20 70 69 78 65 6c 20 6f | 6e 20 74 68 65 20 73 63 | pixel o|n the sc|
|000027d0| 61 6e 6c 69 6e 65 2c 20 | 74 68 65 20 63 6f 6e 74 |anline, |the cont|
|000027e0| 72 61 73 74 20 62 65 74 | 77 65 65 6e 20 69 74 20 |rast bet|ween it |
|000027f0| 61 6e 64 20 69 74 73 0a | 66 6f 75 72 20 69 6d 6d |and its.|four imm|
|00002800| 65 64 69 61 74 65 20 6e | 65 69 67 68 62 6f 72 73 |ediate n|eighbors|
|00002810| 20 69 73 20 63 6f 6d 70 | 75 74 65 64 2e 20 20 49 | is comp|uted. I|
|00002820| 66 20 74 68 69 73 20 63 | 6f 6e 74 72 61 73 74 20 |f this c|ontrast |
|00002830| 69 73 20 67 72 65 61 74 | 65 72 0a 74 68 61 6e 20 |is great|er.than |
|00002840| 61 20 75 73 65 72 2d 73 | 70 65 63 69 66 69 65 64 |a user-s|pecified|
|00002850| 20 6d 61 78 69 6d 75 6d | 20 69 6e 20 61 6e 79 20 | maximum| in any |
|00002860| 63 6f 6c 6f 72 20 63 68 | 61 6e 6e 65 6c 2c 0a 74 |color ch|annel,.t|
|00002870| 68 65 20 70 69 78 65 6c | 20 61 6e 64 20 69 74 73 |he pixel| and its|
|00002880| 0a 6e 65 69 67 68 62 6f | 72 73 20 61 72 65 20 61 |.neighbo|rs are a|
|00002890| 6c 6c 20 73 75 70 65 72 | 73 61 6d 70 6c 65 64 20 |ll super|sampled |
|000028a0| 62 79 20 66 69 72 69 6e | 67 20 61 6e 20 61 64 64 |by firin|g an add|
|000028b0| 69 74 69 6f 6e 61 6c 0a | 7b 24 6e 75 6d 73 61 6d |itional.|{$numsam|
|000028c0| 70 6c 65 73 5e 32 20 2d | 31 24 7d 20 72 61 79 73 |ples^2 -|1$} rays|
|000028d0| 20 74 68 72 6f 75 67 68 | 20 74 68 6f 73 65 20 70 | through| those p|
|000028e0| 69 78 65 6c 73 20 74 68 | 61 74 20 68 61 76 65 20 |ixels th|at have |
|000028f0| 6e 6f 74 20 61 6c 72 65 | 61 64 79 20 62 65 65 6e |not alre|ady been|
|00002900| 0a 73 75 70 65 72 73 61 | 6d 70 6c 65 64 2e 20 20 |.supersa|mpled. |
|00002910| 54 68 69 73 20 70 72 6f | 63 65 73 73 20 69 73 20 |This pro|cess is |
|00002920| 72 65 70 65 61 74 65 64 | 20 66 6f 72 20 74 68 65 |repeated| for the|
|00002930| 20 63 75 72 72 65 6e 74 | 20 73 63 61 6e 6c 69 6e | current| scanlin|
|00002940| 65 0a 75 6e 74 69 6c 20 | 61 20 70 61 73 73 20 69 |e.until |a pass i|
|00002950| 73 20 6d 61 64 65 20 77 | 69 74 68 6f 75 74 20 61 |s made w|ithout a|
|00002960| 6e 79 0a 70 69 78 65 6c | 20 62 65 69 6e 67 20 73 |ny.pixel| being s|
|00002970| 75 70 65 72 73 61 6d 70 | 6c 65 64 2e 0a 0a 5c 62 |upersamp|led...\b|
|00002980| 65 67 69 6e 7b 64 65 66 | 6b 65 79 7d 7b 63 6f 6e |egin{def|key}{con|
|00002990| 74 72 61 73 74 7d 7b 7b | 5c 65 6d 20 72 65 64 63 |trast}{{|\em redc|
|000029a0| 6f 6e 74 20 67 72 65 65 | 6e 63 6f 6e 74 20 62 6c |ont gree|ncont bl|
|000029b0| 75 65 63 6f 6e 74 7d 7d | 0a 09 53 65 74 20 74 68 |uecont}}|..Set th|
|000029c0| 65 20 6d 61 78 69 6d 75 | 6d 20 61 6c 6c 6f 77 65 |e maximu|m allowe|
|000029d0| 64 20 63 6f 6e 74 72 61 | 73 74 20 62 65 74 77 65 |d contra|st betwe|
|000029e0| 65 6e 20 66 6f 75 72 20 | 63 6f 6c 6f 72 0a 09 73 |en four |color..s|
|000029f0| 61 6d 70 6c 65 73 20 77 | 68 65 6e 20 61 64 61 70 |amples w|hen adap|
|00002a00| 74 69 76 65 20 73 75 70 | 65 72 73 61 6d 70 6c 69 |tive sup|ersampli|
|00002a10| 6e 67 20 69 73 20 75 73 | 65 64 2e 0a 09 54 68 65 |ng is us|ed...The|
|00002a20| 20 63 6f 6e 74 72 61 73 | 74 20 74 65 73 74 20 69 | contras|t test i|
|00002a30| 73 20 61 70 70 6c 69 65 | 64 20 74 6f 20 65 61 63 |s applie|d to eac|
|00002a40| 68 20 63 6f 6c 6f 72 0a | 09 63 68 61 6e 6e 65 6c |h color.|.channel|
|00002a50| 20 73 65 70 61 72 61 74 | 65 6c 79 2e 0a 5c 65 6e | separat|ely..\en|
|00002a60| 64 7b 64 65 66 6b 65 79 | 7d 0a 54 68 65 20 64 65 |d{defkey|}.The de|
|00002a70| 66 61 75 6c 74 20 6d 61 | 78 69 6d 75 6d 20 63 6f |fault ma|ximum co|
|00002a80| 6e 74 72 61 73 74 20 76 | 61 6c 75 65 73 20 66 6f |ntrast v|alues fo|
|00002a90| 72 20 74 68 65 20 72 65 | 64 2c 20 67 72 65 65 6e |r the re|d, green|
|00002aa0| 2c 20 61 6e 64 20 62 6c | 75 65 0a 63 68 61 6e 6e |, and bl|ue.chann|
|00002ab0| 65 6c 73 20 61 72 65 20 | 30 2e 32 35 2c 20 30 2e |els are |0.25, 0.|
|00002ac0| 32 2c 20 61 6e 64 20 30 | 2e 34 2c 20 72 65 73 70 |2, and 0|.4, resp|
|00002ad0| 65 63 74 69 76 65 6c 79 | 2e 0a 0a 5c 62 65 67 69 |ectively|...\begi|
|00002ae0| 6e 7b 64 65 66 6b 65 79 | 7d 7b 73 61 6d 70 6c 65 |n{defkey|}{sample|
|00002af0| 7d 7b 7b 5c 65 6d 20 6e | 7d 20 5b 7b 5c 74 74 20 |}{{\em n|} [{\tt |
|00002b00| 6e 6f 6a 69 74 74 65 72 | 7d 5d 7d 0a 09 55 73 65 |nojitter|}]}..Use|
|00002b10| 20 24 6e 5e 7b 32 7d 20 | 24 20 73 61 6d 70 6c 65 | $n^{2} |$ sample|
|00002b20| 73 20 77 68 65 6e 20 70 | 65 72 66 6f 72 6d 69 6e |s when p|erformin|
|00002b30| 67 20 6a 69 74 74 65 72 | 65 64 0a 09 73 61 6d 70 |g jitter|ed..samp|
|00002b40| 6c 69 6e 67 2e 20 20 54 | 68 65 20 6d 61 78 69 6d |ling. T|he maxim|
|00002b50| 75 6d 20 6c 65 67 61 6c | 20 76 61 6c 75 65 20 69 |um legal| value i|
|00002b60| 73 20 35 2e 0a 09 49 66 | 20 7b 5c 74 74 20 6e 6f |s 5...If| {\tt no|
|00002b70| 6a 69 74 74 65 72 7d 20 | 69 73 20 73 70 65 63 69 |jitter} |is speci|
|00002b80| 66 69 65 64 2c 20 73 61 | 6d 70 6c 65 20 6c 6f 63 |fied, sa|mple loc|
|00002b90| 61 74 69 6f 6e 73 0a 09 | 61 6e 64 20 74 69 6d 65 |ations..|and time|
|00002ba0| 73 20 77 69 6c 6c 20 6e | 6f 74 20 62 65 20 6a 69 |s will n|ot be ji|
|00002bb0| 74 74 65 72 65 64 2e 0a | 5c 65 6e 64 7b 64 65 66 |ttered..|\end{def|
|00002bc0| 6b 65 79 7d 0a 42 79 20 | 64 65 66 61 75 6c 74 2c |key}.By |default,|
|00002bd0| 20 24 33 5e 7b 32 7d 24 | 20 6a 69 74 74 65 72 65 | $3^{2}$| jittere|
|00002be0| 64 20 73 61 6d 70 6c 65 | 73 20 61 72 65 20 74 61 |d sample|s are ta|
|00002bf0| 6b 65 6e 2e 0a 0a 41 20 | 67 69 76 65 6e 20 73 65 |ken...A |given se|
|00002c00| 74 20 6f 66 20 73 61 6d | 70 6c 65 20 76 61 6c 75 |t of sam|ple valu|
|00002c10| 65 73 20 6d 75 73 74 20 | 62 65 20 66 69 6c 74 65 |es must |be filte|
|00002c20| 72 65 64 0a 69 6e 20 6f | 72 64 65 72 20 74 6f 0a |red.in o|rder to.|
|00002c30| 61 73 73 69 67 6e 20 61 | 20 63 6f 6c 6f 72 20 74 |assign a| color t|
|00002c40| 6f 20 61 20 70 69 78 65 | 6c 2e 20 20 49 64 65 61 |o a pixe|l. Idea|
|00002c50| 6c 6c 79 2c 20 77 68 65 | 6e 20 70 65 72 66 6f 72 |lly, whe|n perfor|
|00002c60| 6d 69 6e 67 20 66 69 6c | 74 65 72 69 6e 67 0a 66 |ming fil|tering.f|
|00002c70| 6f 72 20 61 20 73 70 65 | 63 69 66 69 63 20 70 69 |or a spe|cific pi|
|00002c80| 78 65 6c 2c 0a 74 68 65 | 20 66 69 6c 74 65 72 20 |xel,.the| filter |
|00002c90| 77 69 6c 6c 20 63 6f 6e | 73 69 64 65 72 20 73 61 |will con|sider sa|
|00002ca0| 6d 70 6c 65 73 20 66 72 | 6f 6d 20 6e 65 69 67 68 |mples fr|om neigh|
|00002cb0| 62 6f 72 69 6e 67 20 72 | 65 67 69 6f 6e 73 2e 20 |boring r|egions. |
|00002cc0| 20 49 6e 0a 7b 5c 72 61 | 79 73 68 61 64 65 7d 2c | In.{\ra|yshade},|
|00002cd0| 20 74 68 65 20 66 69 6c | 74 65 72 69 6e 67 20 61 | the fil|tering a|
|00002ce0| 70 70 6c 69 65 64 20 74 | 6f 20 61 20 70 69 78 65 |pplied t|o a pixe|
|00002cf0| 6c 20 6d 61 6b 65 73 20 | 75 73 65 20 6f 66 20 73 |l makes |use of s|
|00002d00| 61 6d 70 6c 65 73 0a 74 | 61 6b 65 6e 20 66 6f 72 |amples.t|aken for|
|00002d10| 20 74 68 61 74 20 70 69 | 78 65 6c 20 61 6c 6f 6e | that pi|xel alon|
|00002d20| 65 2e 20 20 48 6f 77 65 | 76 65 72 2c 20 6f 6e 65 |e. Howe|ver, one|
|00002d30| 20 6d 61 79 20 69 6e 63 | 72 65 61 73 65 20 74 68 | may inc|rease th|
|00002d40| 65 20 73 69 7a 65 0a 6f | 66 20 74 68 65 20 66 69 |e size.o|f the fi|
|00002d50| 6c 74 65 72 20 74 68 61 | 74 20 69 73 20 61 70 70 |lter tha|t is app|
|00002d60| 6c 69 65 64 20 69 6e 20 | 6f 72 64 65 72 20 74 6f |lied in |order to|
|00002d70| 20 61 70 70 72 6f 78 69 | 6d 61 74 65 20 74 68 65 | approxi|mate the|
|00002d80| 20 72 65 73 75 6c 74 73 | 0a 61 20 6d 6f 72 65 20 | results|.a more |
|00002d90| 72 6f 62 75 73 74 20 66 | 69 6c 74 65 72 69 6e 67 |robust f|iltering|
|00002da0| 20 73 63 68 65 6d 65 2e | 0a 0a 5c 62 65 67 69 6e | scheme.|..\begin|
|00002db0| 7b 64 65 66 6b 65 79 7d | 7b 66 69 6c 74 65 72 7d |{defkey}|{filter}|
|00002dc0| 7b 7b 5c 65 6d 20 74 79 | 70 65 7d 20 5b 7b 5c 65 |{{\em ty|pe} [{\e|
|00002dd0| 6d 20 77 69 64 74 68 7d | 5d 7d 0a 09 55 73 65 20 |m width}|]}..Use |
|00002de0| 74 68 65 20 69 6e 64 69 | 63 61 74 65 64 20 66 69 |the indi|cated fi|
|00002df0| 6c 74 65 72 20 74 79 70 | 65 20 77 69 74 68 20 74 |lter typ|e with t|
|00002e00| 68 65 20 67 69 76 65 6e | 20 77 69 64 74 68 2c 0a |he given| width,.|
|00002e10| 09 69 6e 20 70 69 78 65 | 6c 73 2e 0a 09 53 75 70 |.in pixe|ls...Sup|
|00002e20| 70 6f 72 74 65 64 20 66 | 69 6c 74 65 72 20 74 79 |ported f|ilter ty|
|00002e30| 70 65 73 20 61 72 65 20 | 7b 5c 74 74 20 67 61 75 |pes are |{\tt gau|
|00002e40| 73 73 7d 20 28 47 61 75 | 73 73 69 61 6e 29 0a 09 |ss} (Gau|ssian)..|
|00002e50| 61 6e 64 20 7b 5c 74 74 | 20 62 6f 78 7d 20 28 74 |and {\tt| box} (t|
|00002e60| 68 65 20 64 65 66 61 75 | 6c 74 29 2e 0a 5c 65 6e |he defau|lt)..\en|
|00002e70| 64 7b 64 65 66 6b 65 79 | 7d 0a 54 68 65 20 64 65 |d{defkey|}.The de|
|00002e80| 66 61 75 6c 74 20 66 69 | 6c 74 65 72 20 77 69 64 |fault fi|lter wid|
|00002e90| 74 68 20 69 73 20 31 2e | 30 20 66 6f 72 20 61 20 |th is 1.|0 for a |
|00002ea0| 62 6f 78 20 66 69 6c 74 | 65 72 2c 20 31 2e 38 20 |box filt|er, 1.8 |
|00002eb0| 66 6f 72 20 61 20 47 61 | 75 73 73 69 61 6e 0a 66 |for a Ga|ussian.f|
|00002ec0| 69 6c 74 65 72 2e 20 20 | 54 68 65 20 66 69 6c 74 |ilter. |The filt|
|00002ed0| 65 72 20 61 6e 64 20 70 | 69 78 65 6c 20 63 65 6e |er and p|ixel cen|
|00002ee0| 74 65 72 73 20 61 6c 77 | 61 79 73 20 63 6f 69 6e |ters alw|ays coin|
|00002ef0| 63 69 64 65 2e 0a 57 68 | 65 6e 20 73 61 6d 70 6c |cide..Wh|en sampl|
|00002f00| 69 6e 67 20 61 20 70 69 | 78 65 6c 2c 20 73 61 6d |ing a pi|xel, sam|
|00002f10| 70 6c 65 73 20 61 72 65 | 20 74 61 6b 65 6e 20 6f |ples are| taken o|
|00002f20| 76 65 72 20 74 68 65 20 | 61 72 65 61 20 6f 66 0a |ver the |area of.|
|00002f30| 74 68 65 20 70 69 78 65 | 6c 20 66 69 6c 74 65 72 |the pixe|l filter|
|00002f40| 2c 20 77 68 69 63 68 20 | 69 73 20 6e 6f 74 20 6e |, which |is not n|
|00002f50| 65 63 65 73 73 61 72 69 | 6c 79 20 74 68 65 20 73 |ecessari|ly the s|
|00002f60| 61 6d 65 20 61 73 20 74 | 68 65 20 61 72 65 61 0a |ame as t|he area.|
|00002f70| 6f 66 20 74 68 65 20 70 | 69 78 65 6c 20 69 74 73 |of the p|ixel its|
|00002f80| 65 6c 66 2e 0a 0a 4a 69 | 74 74 65 72 65 64 20 73 |elf...Ji|ttered s|
|00002f90| 61 6d 70 6c 69 6e 67 20 | 69 73 20 75 73 65 64 20 |ampling |is used |
|00002fa0| 69 6e 20 7b 5c 72 61 79 | 73 68 61 64 65 7d 20 74 |in {\ray|shade} t|
|00002fb0| 6f 20 73 61 6d 70 6c 65 | 20 65 78 74 65 6e 64 65 |o sample| extende|
|00002fc0| 64 20 6c 69 67 68 74 0a | 73 6f 75 72 63 65 73 20 |d light.|sources |
|00002fd0| 61 73 20 77 65 6c 6c 2e | 20 20 41 20 74 6f 74 61 |as well.| A tota|
|00002fe0| 6c 20 6f 66 20 24 73 61 | 6d 70 6c 65 73 5e 32 24 |l of $sa|mples^2$|
|00002ff0| 20 73 61 6d 70 6c 65 73 | 20 61 72 65 20 74 61 6b | samples| are tak|
|00003000| 65 6e 20 6f 66 0a 65 61 | 63 68 20 65 78 74 65 6e |en of.ea|ch exten|
|00003010| 64 65 64 20 6c 69 67 68 | 74 20 73 6f 75 72 63 65 |ded ligh|t source|
|00003020| 20 69 6e 20 6f 72 64 65 | 72 20 74 6f 20 64 65 74 | in orde|r to det|
|00003030| 65 72 6d 69 6e 65 20 74 | 68 65 20 65 78 74 65 6e |ermine t|he exten|
|00003040| 74 20 6f 66 20 73 68 61 | 64 6f 77 69 6e 67 2e 0a |t of sha|dowing..|
|00003050| 0a 5c 73 65 63 74 69 6f | 6e 7b 54 68 65 20 52 61 |.\sectio|n{The Ra|
|00003060| 79 20 54 72 65 65 7d 0a | 0a 57 68 65 6e 20 72 61 |y Tree}.|.When ra|
|00003070| 79 20 74 72 61 63 69 6e | 67 20 61 20 73 63 65 6e |y tracin|g a scen|
|00003080| 65 2c 20 72 65 66 6c 65 | 63 74 65 64 20 6f 72 20 |e, refle|cted or |
|00003090| 74 72 61 6e 73 6d 69 74 | 74 65 64 20 72 61 79 73 |transmit|ted rays|
|000030a0| 20 6d 61 79 20 73 74 72 | 69 6b 65 0a 6f 74 68 65 | may str|ike.othe|
|000030b0| 72 20 72 65 66 6c 65 63 | 74 69 76 65 20 6f 72 20 |r reflec|tive or |
|000030c0| 74 72 61 6e 73 70 61 72 | 65 6e 74 20 6f 62 6a 65 |transpar|ent obje|
|000030d0| 63 74 73 2e 20 20 46 75 | 72 74 68 65 72 20 72 65 |cts. Fu|rther re|
|000030e0| 66 6c 65 63 74 65 64 20 | 6f 72 0a 74 72 61 6e 73 |flected |or.trans|
|000030f0| 6d 69 74 74 65 64 20 72 | 61 79 73 20 77 69 6c 6c |mitted r|ays will|
|00003100| 20 62 65 20 73 70 61 77 | 6e 65 64 2c 20 61 6e 64 | be spaw|ned, and|
|00003110| 20 73 6f 20 6f 6e 2e 20 | 20 54 61 6b 65 6e 20 74 | so on. | Taken t|
|00003120| 6f 67 65 74 68 65 72 2c | 20 73 75 63 68 0a 61 20 |ogether,| such.a |
|00003130| 66 61 6d 69 6c 79 20 6f | 66 20 72 61 79 73 20 69 |family o|f rays i|
|00003140| 73 20 74 65 72 6d 65 64 | 20 74 68 65 20 7b 5c 65 |s termed| the {\e|
|00003150| 6d 20 72 61 79 20 74 72 | 65 65 7d 2e 20 20 43 61 |m ray tr|ee}. Ca|
|00003160| 72 65 20 6d 75 73 74 20 | 62 65 20 74 61 6b 65 6e |re must |be taken|
|00003170| 0a 74 6f 20 63 6f 6e 74 | 72 6f 6c 20 74 68 65 20 |.to cont|rol the |
|00003180| 64 65 70 74 68 20 6f 66 | 20 74 68 69 73 20 74 72 |depth of| this tr|
|00003190| 65 65 3a 20 20 49 66 20 | 69 74 20 69 73 20 61 6c |ee: If |it is al|
|000031a0| 6c 6f 77 65 64 20 74 6f | 20 67 72 6f 77 20 74 6f |lowed to| grow to|
|000031b0| 6f 20 64 65 65 70 6c 79 | 2c 0a 6f 6e 65 20 6d 61 |o deeply|,.one ma|
|000031c0| 79 20 73 70 65 6e 64 20 | 61 20 67 72 65 61 74 20 |y spend |a great |
|000031d0| 64 65 61 6c 20 6f 66 20 | 74 69 6d 65 20 63 6f 6d |deal of |time com|
|000031e0| 70 75 74 69 6e 67 20 72 | 61 79 73 20 74 68 61 74 |puting r|ays that|
|000031f0| 20 63 6f 6e 74 72 69 62 | 75 74 65 20 6c 69 74 74 | contrib|ute litt|
|00003200| 6c 65 0a 74 6f 20 74 68 | 65 20 66 69 6e 61 6c 20 |le.to th|e final |
|00003210| 70 69 63 74 75 72 65 3b | 20 69 66 20 69 74 20 69 |picture;| if it i|
|00003220| 73 20 6e 6f 74 20 61 6c | 6c 6f 77 65 64 20 74 6f |s not al|lowed to|
|00003230| 20 67 72 6f 77 20 66 61 | 72 20 65 6e 6f 75 67 68 | grow fa|r enough|
|00003240| 2c 20 74 68 69 73 0a 70 | 72 65 6d 61 74 75 72 65 |, this.p|remature|
|00003250| 20 74 72 65 65 20 70 72 | 75 6e 69 6e 67 20 6d 61 | tree pr|uning ma|
|00003260| 79 20 62 65 20 65 76 69 | 64 65 6e 74 20 69 6e 20 |y be evi|dent in |
|00003270| 74 68 65 20 69 6d 61 67 | 65 2e 0a 0a 7b 5c 52 61 |the imag|e...{\Ra|
|00003280| 79 73 68 61 64 65 7d 20 | 70 72 6f 76 69 64 65 73 |yshade} |provides|
|00003290| 20 74 77 6f 20 63 6f 6d | 70 6c 65 6d 65 6e 74 61 | two com|plementa|
|000032a0| 72 79 20 6d 65 74 68 6f | 64 73 20 66 6f 72 20 63 |ry metho|ds for c|
|000032b0| 6f 6e 74 72 6f 6c 6c 69 | 6e 67 20 74 68 65 20 64 |ontrolli|ng the d|
|000032c0| 65 70 74 68 0a 6f 66 20 | 74 68 65 20 72 61 79 20 |epth.of |the ray |
|000032d0| 74 72 65 65 2e 20 20 4f | 6e 65 20 6d 65 74 68 6f |tree. O|ne metho|
|000032e0| 64 20 73 65 74 73 20 61 | 6e 20 61 62 73 6f 6c 75 |d sets a|n absolu|
|000032f0| 74 65 20 6d 61 78 69 6d | 75 6d 20 66 6f 72 20 74 |te maxim|um for t|
|00003300| 68 65 20 74 72 65 65 2e | 20 20 54 68 65 0a 6f 74 |he tree.| The.ot|
|00003310| 68 65 72 20 61 6c 6c 6f | 77 73 20 6f 6e 65 20 74 |her allo|ws one t|
|00003320| 6f 20 61 64 61 70 74 69 | 76 65 6c 79 20 70 72 75 |o adapti|vely pru|
|00003330| 6e 65 20 61 20 74 72 65 | 65 20 61 73 20 69 74 20 |ne a tre|e as it |
|00003340| 67 72 6f 77 73 20 73 6f | 20 74 68 61 74 20 60 60 |grows so| that ``|
|00003350| 75 6e 69 6d 70 6f 72 74 | 61 6e 74 27 27 0a 72 61 |unimport|ant''.ra|
|00003360| 79 73 20 61 72 65 20 6e | 6f 74 20 73 70 61 77 6e |ys are n|ot spawn|
|00003370| 65 64 2e 0a 0a 5c 62 65 | 67 69 6e 7b 64 65 66 6b |ed...\be|gin{defk|
|00003380| 65 79 7d 7b 6d 61 78 64 | 65 70 74 68 7d 7b 7b 5c |ey}{maxd|epth}{{\|
|00003390| 65 6d 20 6c 65 76 65 6c | 7d 7d 0a 09 44 6f 20 6e |em level|}}..Do n|
|000033a0| 6f 74 20 73 70 61 77 6e | 20 72 61 79 73 20 64 65 |ot spawn| rays de|
|000033b0| 65 70 65 72 20 74 68 61 | 6e 20 74 68 6f 73 65 20 |eper tha|n those |
|000033c0| 61 74 20 74 68 65 20 67 | 69 76 65 6e 20 7b 5c 65 |at the g|iven {\e|
|000033d0| 6d 20 6c 65 76 65 6c 7d | 2e 0a 5c 65 6e 64 7b 64 |m level}|..\end{d|
|000033e0| 65 66 6b 65 79 7d 0a 52 | 61 79 73 20 66 72 6f 6d |efkey}.R|ays from|
|000033f0| 20 74 68 65 20 65 79 65 | 20 61 72 65 20 6f 66 20 | the eye| are of |
|00003400| 64 65 70 74 68 20 7a 65 | 72 6f 2e 20 20 54 68 65 |depth ze|ro. The|
|00003410| 20 64 65 66 61 75 6c 74 | 20 76 61 6c 75 65 20 66 | default| value f|
|00003420| 6f 72 0a 7b 5c 65 6d 20 | 6c 65 76 65 6c 7d 20 69 |or.{\em |level} i|
|00003430| 73 20 31 35 2e 0a 54 68 | 69 73 20 64 65 70 74 68 |s 15..Th|is depth|
|00003440| 20 6d 61 79 20 61 6c 73 | 6f 20 62 65 20 73 65 74 | may als|o be set|
|00003450| 20 66 72 6f 6d 20 74 68 | 65 20 63 6f 6d 6d 61 6e | from th|e comman|
|00003460| 64 20 6c 69 6e 65 20 74 | 68 72 6f 75 67 68 20 74 |d line t|hrough t|
|00003470| 68 65 20 7b 5c 74 74 20 | 2d 44 7d 20 6f 70 74 69 |he {\tt |-D} opti|
|00003480| 6f 6e 2e 0a 0a 5c 62 65 | 67 69 6e 7b 64 65 66 6b |on...\be|gin{defk|
|00003490| 65 79 7d 7b 63 75 74 6f | 66 66 7d 7b 7b 5c 65 6d |ey}{cuto|ff}{{\em|
|000034a0| 20 74 68 72 65 73 68 6f | 6c 64 7d 7d 0a 09 44 6f | thresho|ld}}..Do|
|000034b0| 20 6e 6f 74 20 73 70 61 | 77 6e 20 72 61 79 73 20 | not spa|wn rays |
|000034c0| 77 68 6f 73 65 20 63 6f | 6e 74 72 69 62 75 74 69 |whose co|ntributi|
|000034d0| 6f 6e 20 74 6f 20 74 68 | 65 20 66 69 6e 61 6c 20 |on to th|e final |
|000034e0| 63 6f 6c 6f 72 20 6f 66 | 0a 09 74 68 65 20 65 79 |color of|..the ey|
|000034f0| 65 20 72 61 79 20 69 73 | 20 6c 65 73 73 20 74 68 |e ray is| less th|
|00003500| 61 6e 20 7b 5c 65 6d 20 | 74 68 72 65 73 68 6f 6c |an {\em |threshol|
|00003510| 64 7d 20 66 6f 72 20 65 | 61 63 68 20 63 6f 6c 6f |d} for e|ach colo|
|00003520| 72 20 63 68 61 6e 6e 65 | 6c 2e 0a 09 54 68 72 65 |r channe|l...Thre|
|00003530| 73 68 6f 6c 64 20 6d 61 | 79 20 62 65 20 67 69 76 |shold ma|y be giv|
|00003540| 65 6e 20 61 73 20 61 20 | 73 69 6e 67 6c 65 20 66 |en as a |single f|
|00003550| 6c 6f 61 74 69 6e 67 2d | 70 6f 69 6e 74 20 76 61 |loating-|point va|
|00003560| 6c 75 65 2c 0a 09 6f 72 | 20 61 73 20 61 20 72 65 |lue,..or| as a re|
|00003570| 64 2d 67 72 65 65 6e 2d | 62 6c 75 65 20 74 72 69 |d-green-|blue tri|
|00003580| 70 6c 65 2e 0a 5c 65 6e | 64 7b 64 65 66 6b 65 79 |ple..\en|d{defkey|
|00003590| 7d 0a 54 68 65 20 64 65 | 66 61 75 6c 74 20 76 61 |}.The de|fault va|
|000035a0| 6c 75 65 20 69 73 20 30 | 2e 30 30 32 2e 20 20 54 |lue is 0|.002. T|
|000035b0| 68 69 73 20 74 68 72 65 | 73 68 6f 6c 64 20 6d 61 |his thre|shold ma|
|000035c0| 79 20 61 6c 73 6f 20 62 | 65 20 73 65 74 20 66 72 |y also b|e set fr|
|000035d0| 6f 6d 0a 74 68 65 20 63 | 6f 6d 6d 61 6e 64 20 6c |om.the c|ommand l|
|000035e0| 69 6e 65 20 74 68 72 6f | 75 67 68 20 74 68 65 20 |ine thro|ugh the |
|000035f0| 7b 5c 74 74 20 2d 54 7d | 20 6f 70 74 69 6f 6e 2e |{\tt -T}| option.|
|00003600| 0a | |. | |
+--------+-------------------------+-------------------------+--------+--------+