1Panotools::Script::LineU:s:eIrmaCgoen(t3r)ibuted Perl DoPcaunmoetnotoaltsi:o:nScript::Line::Image(3)
2
3
4
6 Panotools::Script::Line::Image - Panotools input image
7
9 A single input image is described by an 'i' line
10
12 Basically the same format as an 'o' line.
13
14 w1000
15 h500 nona requires the width and height of input images wheras PTStitcher/mender don't
16
17 f0 projection format,
18 0 - rectilinear (normal lenses)
19 1 - Panoramic (Scanning cameras like Noblex)
20 2 - Circular fisheye
21 3 - full-frame fisheye
22 4 - PSphere, equirectangular
23 7 - Mirror (a spherical mirror)
24 8 - Orthographic fisheye
25 10 - Stereographic fisheye
26 21 - Equisolid fisheye
27
28 v82 horizontal field of view of image (required)
29 y0 yaw angle (required)
30 p43 pitch angle (required)
31 r0 roll angle (required)
32 a,b,c lens correction coefficients (optional)
33 (see http://www.fh-furtwangen.de/~dersch/barrel/barrel.html)
34 d,e initial lens offset in pixels(defaults d0 e0, optional).
35 Used to correct for offset from center of image
36 d - horizontal offset,
37 e - vertical offset
38 g,t initial lens shear. Use to remove slight misalignment
39 of the line scanner relative to the film transport
40 g - horizontal shear
41 t - vertical shear
42 j stack number
43
44 Eev exposure of image in EV (exposure values)
45 Er white balance factor for red channel
46 Eb white balance factor for blue channel
47
48 Ra EMoR response model from the Computer Vision Lab at Columbia University
49 Rb This models the camera response curve
50 Rc
51 Rd
52 Re
53
54 TiX,TiY,TiZ Tilt on x axis, y axis, z axis
55 TiS Scaling of field of view in the tilt transformation
56
57 TrX,TrY,TrZ Translation on x axis, y axis, z axis
58
59 Te0,Te1,Te2,Te3 Test parameters
60
61 Vm vignetting correction mode (default 0):
62 0: no vignetting correction
63 1: radial vignetting correction (see j,k,l,o options)
64 2: flatfield vignetting correction (see p option)
65 4: proportional correction: i_new = i / corr.
66 This mode is recommended for use with linear data.
67 If the input data is gamma corrected, try adding g2.2
68 to the m line.
69
70 default is additive correction: i_new = i + corr
71
72 Both radial and flatfield correction can be combined with the
73 proportional correction by adding 4.
74 Examples: i1 - radial polynomial correction by addition.
75 The coefficients j,k,l,o must be specified.
76 i5 - radial polynomial correction by division.
77 The coefficients j,k,l,o must be specified.
78 i6 - flatfield correction by division.
79 The flatfield image should be specified with the p option
80
81 Va,Vb,Vc,Vd vignetting correction coefficients. (defaults: 0,0,0,0)
82 ( 0, 2, 4, 6 order polynomial coefficients):
83 corr = ( i + j*r^2 + k*r^4 + l*r^6), where r is the distance from the image center
84 The corrected pixel value is calculated with: i_new = i_old + corr
85 if additive correction is used (default)
86 for proportional correction (h5): i_new = i_old / corr;
87
88 Vx,Vy radial vignetting correction offset in pixels (defaults q0 w0, optional).
89 Used to correct for offset from center of image
90 Vx - horizontal offset
91 Vy - vertical offset
92
93 S100,600,100,800 Selection(l,r,t,b), Only pixels inside the rectangle will be used for conversion.
94 Original image size is used for all image parameters
95 (e.g. field-of-view) refer to the original image.
96 Selection can be outside image dimension.
97 The selection will be circular for circular fisheye images, and
98 rectangular for all other projection formats
99
100 nName file name of the input image.
101
102 i f2 r0 p0 y0 v183 a0 b-0.1 c0 S100,600,100,800 n"photo1.jpg"
103 i f2 r0 p0 y180 v183 a0 b-0.1 c0 S100,600,100,800 n"photo1.jpg"
104
105 Rotate transform the image, angles in degrees:
106
107 $i->Transform ($roll, $pitch, $yaw);
108
109 Each image attribute (v, a, b, c etc...) can be read like so:
110
111 $fov = $i->v;
112
113 Note that this will return either the value (56.7) or a reference to
114 another image (=0). If you supply a Panotools::Script object as a
115 parameter then the reference will be resolved and you will always get
116 the value:
117
118 $fov = $i->v ($pto);
119
120 Get the absolute path to the image file
121
122 $i->Path ('/path/to/project.pto');
123
124 If a .pto project isn't specified then paths are assumed to be relatve
125 to cwd
126
127 For any given coordinate in this image (top left is 0,0), calculate an
128 x,y,z cartesian coordinate, accounting for lens distortion, projection
129 and rotation.
130
131 $coor = $i->To_Cartesian ($pto, [23,45]);
132 ($x, $y, $z) = @{$coor};
133
134 Query distance (radius) to photo in pixels:
135
136 $pix_radius = $i->Radius ($pto);
137
138
139
140perl v5.12.1 2010-01-05 Panotools::Script::Line::Image(3)