ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/doc/man/man1/rtcontrib.1
(Generate patch)

Comparing ray/doc/man/man1/rtcontrib.1 (file contents):
Revision 1.1 by greg, Thu May 26 06:55:22 2005 UTC vs.
Revision 1.4 by greg, Thu May 26 21:03:22 2005 UTC

# Line 1 | Line 1
1   .\" RCSid "$Id$"
2 < .TH RPIECE 1 5/25/05 RADIANCE
2 > .TH RTCONTRIB 1 5/25/05 RADIANCE
3   .SH NAME
4   rtcontrib - compute contributions in a RADIANCE scene
5   .SH SYNOPSIS
# Line 15 | Line 15 | rtcontrib - compute contributions in a RADIANCE scene
15   ][
16   .B "\-b binv"
17   ]
18 + .B "\-m mod .."
19   [
20   .B $EVAR
21   ]
# Line 24 | Line 25 | rtcontrib - compute contributions in a RADIANCE scene
25   [
26   rtrace options
27   ]
27 .B "\-m mod .."
28   .B octree
29 + .br
30 + .B "rtcontrib [ options ] \-defaults"
31   .SH DESCRIPTION
32   .I Rtcontrib
33   computes ray contributions (i.e., color coefficients)
34   for objects whose modifiers are named in one or more
35   .I \-m
36   settings.
37 < These modifiers are usually materials associated with specific
38 < light sources, though they could correspond to intermediate objects as well.
39 < The resulting contributions may then be used in linear combination to
37 > These modifiers are usually materials associated with
38 > light sources or sky domes, and must directly modify some geometric
39 > primitives to be considered in the output.
40 > The output of
41 > .I rtcontrib
42 > has many potential uses.
43 > Source contributions can be used as components in linear combination to
44   reproduce any desired variation, e.g., simulating lighting controls or
45   changing sky conditions via daylight coefficients.
46   More generally,
47   .I rtcontrib
48 < can compute general input-output relationships in optical
49 < systems, such as light pipes and shading devices.
48 > can be used to compute arbitrary input-output relationships in optical
49 > systems, such as luminaires, light pipes, and shading devices.
50   .PP
51 < .I Rtrace(1)
52 < is called to calculate the contributions for each input ray,
51 > .I Rtcontrib
52 > calls
53 > .I rtrace(1)
54 > to calculate the contributions for each input ray,
55   and the output tallies are sent to one or more files according to the
56   .I \-o
57   specification.
58 < If the output file specification contains a "%s" format, this will be
58 > If an output specification contains a "%s" format, this will be
59   replaced by the modifier name.
60   The
61   .I \-b
62   option may be used to further define
63 < a "bin number" within each object if finer resolution is desired, and
64 < will be applied to a "%d" format in the output file
63 > a "bin number" within each object if finer resolution is needed, and
64 > this will be applied to a "%d" format in the output file
65   specification if present.
66 < (The actual bin number is computed at run time based on ray direction
67 < and surface intersection, as described below.)\0
66 > The actual bin number is computed at run time based on ray direction
67 > and surface intersection, as described below.
68   The most recent
69   .I \-b
70   and
71   .I \-o
72 < options (to the left) of each
72 > options to the left of each
73   .I \-m
74 < setting affect only that modifier, and the ordering
75 < of other options is unimportant.
74 > setting affect only that modifier.
75 > (The ordering of other options is unimportant.)\0
76   .PP
77 < Input and output format defaults to plain text, where each ray's
78 < origin and direction (6 real values) must appear together per
79 < line of input, and one line of output is produced per output file
80 < file per ray.
81 < Alternative input and output formats may be specified using the
82 < .I \-f[io]
83 < option, which is explained in the
84 < .I rtrace
85 < man page along with the associated
86 < .I \-x
87 < and
88 < .I \-y
89 < resolution settings.
90 < In particular, the 'c' output setting
91 < together with positive dimensions for
92 < .I \-x
93 < and
94 < .I \-y
95 < will produce an uncompressed RADIANCE picture,
96 < suitable for manipulation with
97 < .I pcomb(1)
98 < and related tools.
77 > If a
78 > .I \-b
79 > expression is defined for a particular modifier,
80 > the bin number will be evaluated at run time for each
81 > ray contribution from
82 > .I rtrace.
83 > Specifically, each ray's world intersection point will be assigned to
84 > the variables Px, Py, and Pz, and the normalized ray direction
85 > will be assigned to Dx, Dy, and Dz.
86 > These parameters may be combined with definitions given in
87 > .I \-e
88 > arguments and files read using the
89 > .I \-f
90 > option.
91 > The computed bin value will be
92 > rounded to the nearest whole number.
93 > This mechanism allows the user to define precise regions or directions
94 > they wish to accumulate, such as the Tregenza sky discretization,
95 > which would be otherwise impossible to specify
96 > as a set of RADIANCE primitives.
97 > The rules and predefined functions available for these expressions are
98 > described in the
99 > .I rcalc(1)
100 > man page.
101   .PP
102   If no
103   .I \-o
104   specification is given, results are written on the standard output in order
105   of modifier (as given on the command line) then bin number.
106 < The same format is used for a simple file name specification
107 < without any embedded "%s" or "%d" formats.
106 > Concatenated data is also sent to a lone output file (i.e., an initial
107 > .I \-o
108 > specification without formatting strings).
109   If a "%s" format appears but no "%d" in the
110   .I \-o
111   specification, then each modifier will have its own output file, with
# Line 108 | Line 119 | with a newline at the end of each ray record.
119   For binary output formats, there is no such delimiter to mark
120   the end of each record.
121   .PP
122 < If a
123 < .I \-b
124 < expression is defined for a particular modifier,
125 < the bin number will be evaluated at run time for each
126 < ray contribution from
127 < .I rtrace.
128 < Specifically, each ray's world intersection point will be assigned to
129 < the variables Px, Py, and Pz, and the normalized ray direction
130 < will be assigned to Dx, Dy, and Dz.
131 < These ray parameters may be combined with any definitions given in
132 < .I \-e
133 < options, or any files read in from
134 < .I \-f
135 < options, to compute the bin, which will be
136 < rounded to the closest whole number.
137 < This mechanism allows the user to define precise regions (or directions)
138 < they wish to accumulate, such as the Tregenza sky grid, which would be
139 < otherwise impossible to specify as a set of RADIANCE primitives.
122 > Input and output format defaults to plain text, where each ray's
123 > origin and direction (6 real values) are given on input,
124 > and one line is produced per output file per ray.
125 > Alternative data representations may be specified by the
126 > .I \-f[io]
127 > option, which is described in the
128 > .I rtrace
129 > man page along with the associated
130 > .I \-x
131 > and
132 > .I \-y
133 > resolution settings.
134 > In particular, the color ('c') output data representation
135 > together with positive dimensions for
136 > .I \-x
137 > and
138 > .I \-y
139 > will produce an uncompressed RADIANCE picture,
140 > suitable for manipulation with
141 > .I pcomb(1)
142 > and related tools.
143   .PP
144   If the
145   .I \-n
146   option is specified with a value greater than 1, multiple
147 < .I rtrace(1)
147 > .I rtrace
148   processes will be used to accelerate computation on a shared
149   memory machine.
150   Note that there is no benefit to using more processes
151 < than there are local CPUs available to do the work.
151 > than there are local CPUs available to do the work, and the
152 > .I rtcontrib
153 > process itself may use a considerable amount of CPU time.
154   .PP
155   Options may be given on the command line and/or read from the
156   environment and/or read from a file.
# Line 142 | Line 158 | A command argument beginning with a dollar sign ('$')
158   replaced by the contents of the given environment variable.
159   A command argument beginning with an at sign ('@') is immediately
160   replaced by the contents of the given file.
161 < .SH EXAMPLE
162 < First
163 < .I rpiece
148 < process is started on the machine "goober":
161 > .SH EXAMPLES
162 > To compute the proportional contributions from sources modified
163 > by "light1" vs. "light2" on a set of illuminance values:
164   .IP "" .2i
165 < goober% echo 1 8 > syncfile
151 < .br
152 < goober% echo -F syncfile -x 1024 -y 1024 -vf view -o picture octree > args
153 < .br
154 < goober% rpiece @args &
165 > rtcontrib -I+ @render.opt -o c_%s.dat -m light1 -m light2 scene.oct < test.dat
166   .PP
167 < Second
168 < .I rpiece
158 < processes is started on the machine "sucker":
167 > To generate a pair of images corresponding to these two lights'
168 > contributions:
169   .IP "" .2i
170 < sucker% rpiece @args &
171 < .SH NOTES
172 < Due to NFS file buffering, the network lock manager is employed to
163 < guarantee consistency in the output file even though non-overlapping
164 < writes are used.
165 < This would tend to slow the process down if
166 < .I rpiece
167 < were to wait for this I/O to complete before starting on the next
168 < piece, so
169 < .I rpiece
170 < forks separate processes to hang around waiting for I/O completion.
171 < The number of processes thus designated is set by the MAXFORK macro
172 < in the program (compiled in the src/util directory).
173 < If the fork call is slow on a system, it may actually be better to
174 < set MAXFORK to zero.
175 < In other cases, the network lock manager may be so slow that this
176 < value should be increased to get the best utilization.
170 > vwrays -ff -x 1024 -y 1024 -vf best.vf |
171 > rtcontrib -ffc `vwrays -d -x 1024 -y 1024 -vf best.vf`
172 > @render.opt -o c_%s.pic -m light1 -m light2 scene.oct
173   .PP
174 < The output picture is not run-length encoded, and can be quite
175 < large.
180 < The approximate size (in kilobytes) can be computed by the simple
181 < formula:
174 > These images may then be recombined using the desired outputs
175 > of light1 and light2:
176   .IP "" .2i
177 < filesize = xres*yres/256
177 > pcomb -c 100 90 75 c_light1.pic -c 50 55 57 c_light2.pic > combined.pic
178   .PP
179 < Make sure that there is enough space on the filesystem to hold the
180 < entire picture before beginning.
181 < Once the picture is finished, the
182 < .I ra_rgbe(1)
189 < program with the -r option may be used to convert to a run-length
190 < encoded picture for more efficient storage, although
191 < .I pfilt(1)
192 < or any of the other Radiance picture filters will do the same
193 < thing.
194 < .PP
195 < The ALRM signal may be used to gracefully terminate an
196 < .I rpiece
197 < process after it finishes the current piece.
198 < This permits other currently running or subsequently started
199 < .I rpiece
200 < process(es) to continue rendering the picture without loss.
201 < The
202 < .I \-T
203 < option will send the ALRM signal to
204 < .I rpiece
205 < after the specified number of (decimal) hours.
206 < This is the best way to force a time limit on the computation,
207 < since information will not be lost, though the process may continue
208 < for some time afterwards to finish its current piece.
209 < .SH BUGS
210 < This program may not work on some systems whose NFS lock manager is
211 < unreliable.
212 < In particular, some System V derivative UNIX systems often have
213 < problems with the network lock manager.
214 < If the output is scrambled or rpict aborts with some ambient file
215 < related problem, you should just remove the ambient file and go
216 < back to normal rendering.
179 > To compute an array of illuminance contributions according to a Tregenza sky:
180 > .IP "" .2i
181 > rtcontrib -b tbin -o sky.dat -m skyglow -b 0 -o ground.dat -m groundglow
182 > @render.opt -f tregenza.cal scene.oct < test.dat
183   .SH AUTHOR
184   Greg Ward
185   .SH "SEE ALSO"

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines