"Fossies" - the Fresh Open Source Software Archive 
Member "gnuastro-0.8/bin/warp/args.h" (12 Dec 2018, 5638 Bytes) of package /linux/privat/gnuastro-0.8.tar.lz:
As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style:
standard) with prefixed line numbers and
code folding option.
Alternatively you can here
view or
download the uninterpreted source code file.
For more information about "args.h" see the
Fossies "Dox" file reference documentation and the last
Fossies "Diffs" side-by-side code changes report:
0.5_vs_0.6.
1 /*********************************************************************
2 Warp - Warp images using projective mapping.
3 Warp is part of GNU Astronomy Utilities (Gnuastro) package.
4
5 Original author:
6 Mohammad Akhlaghi <mohammad@akhlaghi.org>
7 Contributing author(s):
8 Copyright (C) 2016-2018, Free Software Foundation, Inc.
9
10 Gnuastro is free software: you can redistribute it and/or modify it
11 under the terms of the GNU General Public License as published by the
12 Free Software Foundation, either version 3 of the License, or (at your
13 option) any later version.
14
15 Gnuastro is distributed in the hope that it will be useful, but
16 WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 General Public License for more details.
19
20 You should have received a copy of the GNU General Public License
21 along with Gnuastro. If not, see <http://www.gnu.org/licenses/>.
22 **********************************************************************/
23 #ifndef ARGS_H
24 #define ARGS_H
25
26
27
28
29
30
31 /* Array of acceptable options. */
32 struct argp_option program_options[] =
33 {
34
35 /* Input. */
36 {
37 "hstartwcs",
38 UI_KEY_HSTARTWCS,
39 "INT",
40 0,
41 "Header keyword number to start reading WCS.",
42 GAL_OPTIONS_GROUP_INPUT,
43 &p->hstartwcs,
44 GAL_TYPE_SIZE_T,
45 GAL_OPTIONS_RANGE_GT_0,
46 GAL_OPTIONS_NOT_MANDATORY,
47 GAL_OPTIONS_NOT_SET
48 },
49 {
50 "hendwcs",
51 UI_KEY_HENDWCS,
52 "INT",
53 0,
54 "Header keyword number to end reading WCS.",
55 GAL_OPTIONS_GROUP_INPUT,
56 &p->hendwcs,
57 GAL_TYPE_SIZE_T,
58 GAL_OPTIONS_RANGE_GT_0,
59 GAL_OPTIONS_NOT_MANDATORY,
60 GAL_OPTIONS_NOT_SET
61 },
62
63
64
65 /* Output. */
66 {
67 "keepwcs",
68 UI_KEY_KEEPWCS,
69 0,
70 0,
71 "Do not apply warp to input's WCS",
72 GAL_OPTIONS_GROUP_OUTPUT,
73 &p->keepwcs,
74 GAL_OPTIONS_NO_ARG_TYPE,
75 GAL_OPTIONS_RANGE_0_OR_1,
76 GAL_OPTIONS_NOT_MANDATORY,
77 GAL_OPTIONS_NOT_SET
78 },
79 {
80 "coveredfrac",
81 UI_KEY_COVEREDFRAC,
82 "FLT",
83 0,
84 "Acceptable fraction of output pixel covered.",
85 GAL_OPTIONS_GROUP_OUTPUT,
86 &p->coveredfrac,
87 GAL_TYPE_FLOAT64,
88 GAL_OPTIONS_RANGE_GE_0_LE_1,
89 GAL_OPTIONS_NOT_MANDATORY,
90 GAL_OPTIONS_NOT_SET
91 },
92
93
94 {
95 0, 0, 0, 0,
96 "Warps:",
97 UI_GROUP_WARPS
98 },
99 {
100 "align",
101 UI_KEY_ALIGN,
102 0,
103 0,
104 "Align the image and celestial axes.",
105 UI_GROUP_WARPS,
106 0,
107 GAL_TYPE_INVALID,
108 GAL_OPTIONS_RANGE_ANY,
109 GAL_OPTIONS_NOT_MANDATORY,
110 GAL_OPTIONS_NOT_SET,
111 ui_add_to_modular_warps_ll
112 },
113 {
114 "rotate",
115 UI_KEY_ROTATE,
116 "FLT",
117 0,
118 "Rotate by the given angle in degrees.",
119 UI_GROUP_WARPS,
120 0,
121 GAL_TYPE_INVALID,
122 GAL_OPTIONS_RANGE_ANY,
123 GAL_OPTIONS_NOT_MANDATORY,
124 GAL_OPTIONS_NOT_SET,
125 ui_add_to_modular_warps_ll
126 },
127 {
128 "scale",
129 UI_KEY_SCALE,
130 "FLT[,FLT]",
131 0,
132 "Scale along the given axis(es).",
133 UI_GROUP_WARPS,
134 0,
135 GAL_TYPE_INVALID,
136 GAL_OPTIONS_RANGE_ANY,
137 GAL_OPTIONS_NOT_MANDATORY,
138 GAL_OPTIONS_NOT_SET,
139 ui_add_to_modular_warps_ll
140 },
141 {
142 "flip",
143 UI_KEY_FLIP,
144 "INT[,INT]",
145 0,
146 "Flip along the given axis(es).",
147 UI_GROUP_WARPS,
148 0,
149 GAL_TYPE_INVALID,
150 GAL_OPTIONS_RANGE_ANY,
151 GAL_OPTIONS_NOT_MANDATORY,
152 GAL_OPTIONS_NOT_SET,
153 ui_add_to_modular_warps_ll
154 },
155 {
156 "shear",
157 UI_KEY_SHEAR,
158 "FLT[,FLT]",
159 0,
160 "Shear along the given axis(es).",
161 UI_GROUP_WARPS,
162 0,
163 GAL_TYPE_INVALID,
164 GAL_OPTIONS_RANGE_ANY,
165 GAL_OPTIONS_NOT_MANDATORY,
166 GAL_OPTIONS_NOT_SET,
167 ui_add_to_modular_warps_ll
168 },
169 {
170 "translate",
171 UI_KEY_TRANSLATE,
172 "FLT[,FLT]",
173 0,
174 "Translate along the given axis(es).",
175 UI_GROUP_WARPS,
176 0,
177 GAL_TYPE_INVALID,
178 GAL_OPTIONS_RANGE_ANY,
179 GAL_OPTIONS_NOT_MANDATORY,
180 GAL_OPTIONS_NOT_SET,
181 ui_add_to_modular_warps_ll
182 },
183 {
184 "project",
185 UI_KEY_PROJECT,
186 "FLT[,FLT]",
187 0,
188 "Project along the given axis(es).",
189 UI_GROUP_WARPS,
190 0,
191 GAL_TYPE_INVALID,
192 GAL_OPTIONS_RANGE_ANY,
193 GAL_OPTIONS_NOT_MANDATORY,
194 GAL_OPTIONS_NOT_SET,
195 ui_add_to_modular_warps_ll
196 },
197 {
198 "matrix",
199 UI_KEY_MATRIX,
200 "STR",
201 0,
202 "Raw transformation matrix, highest priority.",
203 UI_GROUP_WARPS,
204 &p->matrix,
205 GAL_TYPE_INVALID,
206 GAL_OPTIONS_RANGE_ANY,
207 GAL_OPTIONS_NOT_MANDATORY,
208 GAL_OPTIONS_NOT_SET,
209 ui_add_to_modular_warps_ll
210 },
211 {
212 "centeroncorner",
213 UI_KEY_CENTERONCORNER,
214 0,
215 0,
216 "Center of coordinates on first pixel corner.",
217 UI_GROUP_WARPS,
218 &p->centeroncorner,
219 GAL_OPTIONS_NO_ARG_TYPE,
220 GAL_OPTIONS_RANGE_0_OR_1,
221 GAL_OPTIONS_NOT_MANDATORY,
222 GAL_OPTIONS_NOT_SET
223 },
224
225
226
227
228
229
230 {0}
231 };
232
233
234
235
236
237 /* Define the child argp structure. */
238 struct argp
239 gal_options_common_child = {gal_commonopts_options,
240 gal_options_common_argp_parse,
241 NULL, NULL, NULL, NULL, NULL};
242
243 /* Use the child argp structure in list of children (only one for now). */
244 struct argp_child
245 children[]=
246 {
247 {&gal_options_common_child, 0, NULL, 0},
248 {0, 0, 0, 0}
249 };
250
251 /* Set all the necessary argp parameters. */
252 struct argp
253 thisargp = {program_options, parse_opt, args_doc, doc, children, NULL, NULL};
254 #endif