ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/doc/man/man1/vwrays.1
Revision: 1.8
Committed: Sat Aug 20 20:57:51 2011 UTC (13 years, 8 months ago) by greg
Branch: MAIN
CVS Tags: rad4R1
Changes since 1.7: +5 -2 lines
Log Message:
Added -u option to vwrays for unbuffered output with -i

File Contents

# Content
1 .\" RCSid "$Id: vwrays.1,v 1.7 2011/08/16 02:22:50 greg Exp $"
2 .TH VWRAYS 1 1/15/99 RADIANCE
3 .SH NAME
4 vwrays - compute rays for a given picture or view
5 .SH SYNOPSIS
6 .B vwrays
7 .B "[ -i -u -f{a|f|d} | -d ]"
8 {
9 .B "view opts .."
10 |
11 .B picture
12 .B [zbuf]
13 }
14 .SH DESCRIPTION
15 .I Vwrays
16 takes a picture or view specification and computes the ray origin and
17 direction corresponding to each pixel in the image.
18 This information may then be passed to
19 .I rtrace(1)
20 to perform other calculations.
21 If a given pixel has no corresponding ray (because it is outside the
22 legal view boundaries), then six zero values are sent instead.
23 .PP
24 The
25 .I \-i
26 option may be used to specify desired pixel positions on the standard
27 input rather than generating all the pixels for a given view.
28 If the
29 .I \-u
30 option is also given, output will be unbuffered.
31 .PP
32 The
33 .I \-f
34 option may be used to set the record format to something other than the
35 default ASCII.
36 Using raw float or double records for example can reduce the time
37 requirements of transferring and interpreting information in
38 .I rtrace.
39 .PP
40 View options may be any combination of standard view parameters described
41 in the
42 .I rpict(1)
43 manual page, including input from a view file with the
44 .I \-vf
45 option.
46 Additionally, the target X and Y dimensions may be specified with
47 .I \-x
48 and
49 .I \-y
50 options, and the pixel aspect ratio may be given with
51 .I \-pa.
52 The default dimensions are 512x512, with a pixel aspect ratio of 1.0.
53 Just as in
54 .I rpict,
55 the X or the Y dimension will be reduced if necessary
56 to best match the specified pixel
57 aspect ratio, unless this ratio is set to zero.
58 The
59 .I \-pj
60 option may be used to jitter samples.
61 The default value of 0 turns off ray jittering.
62 .PP
63 If the
64 .I \-d
65 option is given, then
66 .I vwrays
67 just prints the computed image dimensions, which are based on the view
68 aspect and the pixel aspect ratio just described.
69 The
70 .I \-ld
71 switch will also be printed, with
72 .I \-ld+
73 if the view file has an aft clipping plane, and
74 .I \-ld-
75 otherwise.
76 This is useful for passing options to the
77 .I rtrace
78 command line.
79 (See below.)
80 .PP
81 If the view contains an aft clipping plane
82 .I (-va
83 option), then the magnitudes of the ray directions will
84 equal the maximum distance for each pixel, which will be interpreted
85 correctly by
86 .I rtrace
87 with the
88 .I \-ld+
89 option.
90 Note that this option should not be given unless there is an aft
91 clipping plane, since the ray direction vectors will be normalized
92 otherwise, which would produce a uniform clipping distance of 1.
93 .PP
94 If a picture is given on the command line rather than a set of view options,
95 then the view and image dimensions are taken from the picture file, and
96 the reported ray origins and directions will match the center of each
97 pixel in the picture (plus optional jitter).
98 .PP
99 If a depth buffer file is given as well, then
100 .I vwrays
101 computes the intersection point of each pixel ray (equal to the ray origin
102 plus the depth times the ray direction), and reports this instead of the
103 ray origin.
104 The reported ray direction will also be reversed.
105 The interpretation of this data is an image of origins and directions
106 for light rays leaving the scene surfaces to strike each pixel.
107 .SH EXAMPLES
108 To compute the ray intersection points and returned directions corresponding
109 to a picture and its depth buffer:
110 .IP "" .2i
111 vwrays scene_v2.hdr scene_v2.zbf > scene_v2.pts
112 .PP
113 To determine what the dimensions of a given view would be:
114 .IP "" .2i
115 vwrays \-d \-vf myview.vf \-x 2048 \-y 2048
116 .PP
117 To generate a RADIANCE picture using
118 .I rtrace
119 instead of
120 .I rpict:
121 .IP "" .2i
122 vwrays \-ff \-vf view1.vf \-x 1024 \-y 1024 |
123 rtrace `vwrays \-d \-vf view1.vf \-x 1024 \-y 1024` \-ffc scene.oct > view1.hdr
124 .SH AUTHOR
125 Greg Ward Larson
126 .SH ACKNOWLEDGMENT
127 This work was supported by Silicon Graphics, Inc.
128 .SH BUGS
129 Although
130 .I vwrays
131 can reproduce any pixel ordering (i.e., any image orientation) when given
132 a rendered picture, it will only produce standard scanline-ordered rays when
133 given a set of view parameters.
134 .SH "SEE ALSO"
135 rcalc(1), rpict(1), rtcontrib(1), rtrace(1)