Update changelog
[Ale.git] / ui / help.h
blobfa4b837d6ab2acbc552e3c9da3823fc1a3a67463
1 // Copyright 2002, 2003, 2004 David Hilvert <dhilvert@auricle.dyndns.org>,
2 // <dhilvert@ugcs.caltech.edu>
4 /* This file is part of the Anti-Lamenessing Engine.
6 The Anti-Lamenessing Engine is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2 of the License, or
9 (at your option) any later version.
11 The Anti-Lamenessing Engine is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with the Anti-Lamenessing Engine; if not, write to the Free Software
18 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
22 * Help messages
25 #define BETWEEN_SECTIONS "\n"
26 #define HEADER_SPACE ""
28 class help {
29 private:
30 const char *package;
31 const char *version;
32 const char *invocation;
33 FILE *help_stream;
36 * Stars
38 * This function produces a line of stars for banner output.
40 void stars(unsigned int n) {
41 for (unsigned int i = 0; i < n; i++) {
42 fprintf(help_stream, "*");
44 fprintf(help_stream, "\n");
49 * Banner
51 * This function aids in locating the start of help output.
53 void banner(const char *name) {
54 const char *package_banner = " Help Text, version ";
55 const char *section_banner = "Section: ";
57 int plen = strlen(package) + strlen(package_banner) + strlen(version);
58 int slen = strlen(section_banner) + strlen(name);
59 int len = (plen > slen) ? plen : slen;
61 fprintf(help_stream, BETWEEN_SECTIONS);
62 stars(len);
63 fprintf(help_stream, "%s%s%s\n", package, package_banner, version);
64 fprintf(help_stream, "%s%s\n", section_banner, name);
65 stars(len);
68 public:
69 help(const char *package, const char *invocation, const char *version) {
70 this->invocation = invocation;
71 this->package = package;
72 this->version = version;
73 this->help_stream = stdout;
77 * Describe how to use this program
79 void usage() {
80 banner("Usage");
81 fprintf(help_stream,
82 BETWEEN_SECTIONS
83 "Usage: %s [<options>] <original-frame> [<supplemental-frame> ...] <output-file>\n"
84 " or: %s [<help option> ...]\n"
85 " or: %s --version\n"
86 BETWEEN_SECTIONS
87 "Help options:\n"
88 HEADER_SPACE
89 "--hu Usage (this message).\n"
90 "--hq Default settings.\n"
91 "--hf Image files.\n"
92 "--he Exclusion regions.\n"
93 "--ha Alignment (not exposure-related).\n"
94 "--hr Rendering (not exposure-related).\n"
95 "--hx Exposure.\n"
96 "--ht Transformation data files.\n"
97 "--hc Control points.\n"
98 "--hl Filtering (PSFs, rendering chains).\n"
99 "--hd Devices.\n"
100 "--hi User Interfaces.\n"
101 "--hp Process details.\n"
102 "--hs Argument scope (Experimental).\n"
103 "--hv Video stream processing (Experimental).\n"
104 "--h3 3D Modeling (Experimental).\n"
105 "--hz Undocumented options.\n"
106 "--hA Concatenate all help pages.\n"
107 "\n",
108 invocation, invocation, invocation);
111 void defaults() {
112 banner("Defaults");
113 fprintf(help_stream,
114 BETWEEN_SECTIONS
115 "Default settings:\n"
116 HEADER_SPACE
117 "--q0 Low quality, high speed. [default]\n"
118 "--qn Low noise, moderate speed.\n"
119 "--q1 Moderate quality and speed; high memory use.\n"
120 "--q2 High quality, low speed.\n"
121 "--qr Range-extended high quality.\n"
122 BETWEEN_SECTIONS
123 "q0 defaults:\n"
124 HEADER_SPACE
125 " --dchain fine:box:1,triangle:2\n"
126 " --achain triangle:2\n"
127 " --ips 0\n"
128 " --exp-noextend\n"
129 " --no-cx\n"
130 " --3d-chain fine:box:1,triangle:2\n"
131 BETWEEN_SECTIONS
132 "Low noise defaults:\n"
133 HEADER_SPACE
134 " --dchain sinc*lanc:6\n"
135 " --achain sinc*lanc:6\n"
136 " --ips 0\n"
137 " --exp-noextend\n"
138 " --no-cx\n"
139 " --3d-chain sinc*lanc:6\n"
140 BETWEEN_SECTIONS
141 "q1 defaults:\n"
142 HEADER_SPACE
143 " --dchain median:fine:sinc*lanc:8,triangle:2\n"
144 " --achain triangle:2\n"
145 " --ips 0\n"
146 " --exp-noextend\n"
147 " --no-cx\n"
148 " --3d-chain median:fine:sinc*lanc:8,triangle:2\n"
149 BETWEEN_SECTIONS
150 "q2 defaults:\n"
151 HEADER_SPACE
152 " --dchain triangle:2\n"
153 " --achain triangle:2\n"
154 " --ips 4\n"
155 " --exp-noextend\n"
156 " --no-cx\n"
157 " --3d-chain median:fine:sinc*lanc:8,triangle:2\n"
158 BETWEEN_SECTIONS
159 "Range-extended defaults:\n"
160 HEADER_SPACE
161 " --dchain triangle:2\n"
162 " --achain triangle:2\n"
163 " --ips 6\n"
164 " --exp-extend\n"
165 " --cx 0.7\n"
166 " --3d-chain median:fine:sinc*lanc:8,triangle:2\n"
167 "\n"
171 void file() {
172 banner("File");
173 fprintf(help_stream,
174 BETWEEN_SECTIONS
175 "Bit depth options:\n"
176 HEADER_SPACE
177 "--8bpc Write 8 bit per channel output [default]\n"
178 "--16bpc Write 16 bit per channel output\n"
179 BETWEEN_SECTIONS
180 "Output format options:\n"
181 HEADER_SPACE
182 #ifdef USE_MAGICK
183 "--auto Determine output file type automatically [default]\n"
184 "--raw Write raw PPM output\n"
185 "--plain Write plain PPM output\n"
186 #else
187 "--raw Write raw PPM output [default]\n"
188 "--plain Write plain PPM output\n"
189 #endif
190 BETWEEN_SECTIONS
191 "Incremental output:\n"
192 HEADER_SPACE
193 "--inc Produce incremental output. [default]\n"
194 "--no-inc Don't produce incremental output.\n"
196 BETWEEN_SECTIONS
197 "Undefined values:\n"
198 HEADER_SPACE
199 "--def-nn <R> Use nearest-neighbor defined values within\n"
200 " radius <R>, zero outside. Default radius is 0.\n"
201 "\n"
204 void alignment() {
205 banner("Alignment");
206 fprintf(help_stream,
207 BETWEEN_SECTIONS
208 "Alignment channel options:\n"
209 HEADER_SPACE
210 "--align-all Align images using all color channels\n"
211 "--align-green Align images using the green channel\n"
212 "--align-sum Align images using a sum of channels [default]\n"
213 BETWEEN_SECTIONS
214 "Transformation options:\n"
215 HEADER_SPACE
216 "--translation Only adjust the position of images\n"
217 "--euclidean Adjust the position and orientation of images [default]\n"
218 "--projective Use projective transformations. Best quality, but slow.\n"
219 BETWEEN_SECTIONS
220 "Alignment following:\n"
221 HEADER_SPACE
222 "--follow Frames align closely with their predecessor. [default]\n"
223 "--identity Frames align closely with the original frame.\n"
224 BETWEEN_SECTIONS
225 "Alignment failure:\n"
226 HEADER_SPACE
227 "--fail-optimal Frames beneath threshold are aligned optimally. [default]\n"
228 "--fail-default Frames beneath threshold keep their default alignment.\n"
229 BETWEEN_SECTIONS
230 "Transformation file operations:\n"
231 HEADER_SPACE
232 "--trans-load <x> Load initial transformation settings from file <x>\n"
233 "--trans-save <x> Save final transformation data in file <x>\n"
234 BETWEEN_SECTIONS
235 "Monte Carlo alignment:\n"
236 HEADER_SPACE
237 "--mc <x> Statically sample ~x%% of available pixels (0 < x < 100)\n"
238 "--no-mc Statically sample all pixels.\n"
239 "--mcd Dynamically sample with robustness checks. [default]\n"
240 "--mcd-removal <x> Check robustness against removing x pixels. (100 is default)\n"
241 BETWEEN_SECTIONS
242 "Tunable parameters:\n"
243 HEADER_SPACE
244 "--metric=x Set the alignment error metric exponent. (2 is default)\n"
245 "--threshold=x Min. match threshold; a perfect match is 100. (0 is default)\n"
246 "--perturb-upper=x Perturbation upper bound pixels/arclength (14%% is default)\n"
247 " ('x%%' uses a fraction of the smallest image dimension.)\n"
248 "--perturb-lower=x Perturbation lower bound pixels/arclength (.125 is default)\n"
249 " ('x%%' uses a fraction of the smallest image dimension.)\n"
250 "--rot-upper=x Rotation-specific upper bound in degrees (32.0 is default)\n"
251 "--bda-mult=x Barrel distortion adjustment multiplier (0.0001 is default)\n"
252 "--bda-rate=x Barrel distortion rate of change maximum (0.0004 is default)\n"
253 "--lod-max=x LOD scale factor is max(1, (2^floor(x))/perturb) (1 is def.)\n"
254 BETWEEN_SECTIONS
255 "Certainty-weighted alignment:\n"
256 HEADER_SPACE
257 "--cw Weight alignment error by certainty.\n"
258 "--no-cw Don't weight alignment error by certainty. [default]\n"
259 BETWEEN_SECTIONS
260 "Alignment weight maps:\n"
261 HEADER_SPACE
262 "--wm <f> <x> <y> Use weight map image <f> at offset (<x>, <y>)\n"
263 BETWEEN_SECTIONS
264 "Frequency-weighted alignment:\n"
265 HEADER_SPACE
266 "--fl <h> <v> <a> High-pass filters: horizontal <h>, vertical <v>, average <a>.\n"
267 " Values should fall between 0 (pass all) and 1 (pass none).\n"
268 #ifndef USE_FFTW
269 "\n"
270 " NOTE: since this build of ALE does not link with FFTW,\n"
271 " this option is not supported. To use this option,\n"
272 " first re-build with FFTW support.\n"
273 "\n"
274 #endif
275 "--flshow <o> Write high-pass filtered data to file <o>.\n"
276 BETWEEN_SECTIONS
277 "Algorithmic alignment weighting:\n"
278 HEADER_SPACE
279 "--wmx <e> <r> <d> Write reference <r>, definition <d>, execute `<e> <f> <d>`,\n"
280 " read weights <r> back.\n"
281 #ifndef USE_UNIX
282 "\n"
283 " NOTE: since this build was not configured with\n"
284 " support for --wmx, this option is not supported.\n"
285 " To use this option, re-build with support for --wmx.\n"
286 #endif
287 BETWEEN_SECTIONS
288 "Perturbation Type [experimental]:\n"
289 HEADER_SPACE
290 "--perturb-output Apply perturbations in output image coordinates. [default]\n"
291 "--perturb-source Apply perturbations in source image coordinates.\n"
292 BETWEEN_SECTIONS
293 "Global searching:\n"
294 HEADER_SPACE
295 "--gs <type> Set global search to <type>, one of:\n"
296 " local Local alignment only [default]\n"
297 " inner Alignment reference image inner region\n"
298 " outer Alignment reference image outer region\n"
299 " all Union of inner and outer\n"
300 " central inner if below threshold or better; else, outer.\n"
301 " points Align by control points. Ignores gs-mo.\n"
302 "--gs-mo <x> Set <x> pixel min. overlap for global search. (16 is default)\n"
303 "\n"
307 void rendering() {
308 banner("Rendering");
309 fprintf(help_stream,
310 BETWEEN_SECTIONS
311 "Mimicking ALE 0.6.0 merging and drizzling (see --hl for details):\n"
312 HEADER_SPACE
313 " --dchain triangle:2 approximates merging.\n"
314 " --dchain fine:box:1 approximates drizzling.\n"
315 BETWEEN_SECTIONS
316 "Image extents:\n"
317 HEADER_SPACE
318 "--extend Increase image extents to accommodate all pixel data.\n"
319 "--no-extend Don't increase extents; crop to original frame. [default]\n"
320 BETWEEN_SECTIONS
321 "Tunable parameters:\n"
322 HEADER_SPACE
323 "--scale=x Scale images by the factor x, where x > 0. (1 is default)\n"
324 "--threshold=x Min. match threshold; a perfect match is 100. (0 is default)\n"
325 BETWEEN_SECTIONS
326 "Irani-Peleg iterative solver (see --hq for --ips defaults):\n"
327 HEADER_SPACE
328 "--ips <i> Run <i> iterations. (see also --hx, --hl and --hd)\n"
329 "--ip-mean Use the mean correction [default]\n"
330 "--ip-median Use the median correction\n"
331 #if 0
332 BETWEEN_SECTIONS
333 "Unsharp Mask (was 'High-frequency Enhancement'):\n"
334 HEADER_SPACE
335 "--usm <m> Apply an unsharp mask with multiplier <m>.\n"
336 " (See also --device, --nlpsf, and --lpsf.)\n"
337 #endif
338 BETWEEN_SECTIONS
339 "Bayer pattern:\n"
340 HEADER_SPACE
341 "--bayer <b> Set the Bayer pattern to <b>, one of:\n"
342 " (clockwise from top left pixel)\n"
343 " rgbg Red-green-blue-green\n"
344 " gbgr Green-blue-green-red\n"
345 " grgb Green-red-green-blue\n"
346 " bgrg Blue-green-red-green\n"
347 " none RGB-RGB-RGB-RGB\n"
348 " Default is none or device-specific.\n"
349 BETWEEN_SECTIONS
350 "Color adjustment:\n"
351 HEADER_SPACE
352 "--exp-mult=c,r,b Adjust all channels by <c>, red by <r>, and blue by <b>.\n"
353 "\n"
356 void filtering() {
357 banner("Filtering");
358 fprintf(help_stream,
359 BETWEEN_SECTIONS
360 "Point-spread functions (used with --ips; see --hr):\n"
361 HEADER_SPACE
362 "--lpsf <p> Set linear colorspace point-spread function to <p>\n"
363 "--nlpsf <p> Set non-linear colorspace point-spread function to <p>\n"
364 " Available point-spread functions:\n"
365 " box=<diameter>\n"
366 " circle=<diameter>\n"
367 " stdin\n"
368 " stdin_vg\n"
369 " <p>+<p> (summation)\n"
370 " <p>^<p> (convolution)\n"
371 " <n>*<p> (multiplication by a scalar <n>)\n"
372 " Default lpsf is either 'box=1.0' or device-specific.\n"
373 " Default nlpsf is either disabled or device-specific.\n"
374 BETWEEN_SECTIONS
375 "Incremental rendering chains:\n"
376 HEADER_SPACE
377 "--wt <w> Set weight threshold for defined pixels (default is 0.1).\n"
378 "--dchain <g> Use chain <g> to render the default output.\n"
379 "--ochain <g> <o> Use chain <g> to render output file <o>.\n"
380 "--achain <g> Use chain <g> to render the alignment reference image.\n"
381 "--afilter <s> Use SSF <s> to interpolate points in alignment.\n"
382 "--3d-chain <g> Use chain <g> by default to render 3d output.\n"
383 " Example chains:\n"
384 " triangle:2 ALE 0.6.0 merging (roughly)\n"
385 " fine:box:1 Drizzling (roughly)\n"
386 " fine:sinc*lanc:8 High-frequency preservation\n"
387 " last:nex:sinc*lanc:8 Useful for video stabilization\n"
388 " fine:box:1,triangle:2 Multi-resolution rendering\n"
389 " fine:sinc*lanc:8,sinc*lanc:8 Multi-resolution rendering\n"
390 " More precisely, chains <g> are one of:\n"
391 " <g1>,<g2> Chain <g1> where defined; <g2> elsewhere.\n"
392 " <i> Use rendering invariant <i>.\n"
393 " Rendering invariants <i> are:\n"
394 " avg:<e> Avg. (mean) value using SSFE <e>.\n"
395 " first:<e> First defined value using SSFE <e>.\n"
396 " last:<e> Last defined value using SSFE <e>.\n"
397 " max:<e> Maximum defined value using SSFE <e>.\n"
398 " min:<e> Minimum defined value using SSFE <e>.\n"
399 " median:<e> Median value using SSFE <e>.\n"
400 " <e> Same as avg:<e>.\n"
401 " Scaled sampling filters with exclusion (SSFE) <e> are:\n"
402 " ex:<s> Use SSF <s>; honor exclusion regions.\n"
403 " nex:<s> Use SSF <s>; don't honor exclusion regions.\n"
404 " <s> Same as ex:<s>\n"
405 " Scaled sampling filters (SSF) <s> are:\n"
406 " fine:<f> filter <f> at output image resolution.\n"
407 " coarse:<f> filter <f> at resolution MIN(in, out).\n"
408 " <f> Same as coarse:<f>.\n"
409 " Sampling filters <f> are:\n"
410 " sinc Sinc filter. (very large diameter)\n"
411 " lanc:<x> Lanczos, diameter <x>.\n"
412 " triangle:<x> Triangle, diameter <x>.\n"
413 " box:<x> Box, diameter <x>.\n"
414 " gauss:<x> Gaussian, standard deviation <x>.\n"
415 " zero Zero function.\n"
416 " <f>*<f> Pointwise multiplication (windowing).\n"
417 " Defaults:\n"
418 " dchain (see --hq)\n"
419 " achain (see --hq)\n"
420 " afilter internal (approximates triangle:2)\n"
421 "\n"
424 void device() {
425 banner("Device");
426 fprintf(help_stream,
427 BETWEEN_SECTIONS
428 "Device (may set PSF, Bayer pattern, exposure, and view angle):\n"
429 HEADER_SPACE
430 "--device <d> Set the capture device to <d>.\n"
431 " Available devices:\n"
432 " xvp610_320x240\n"
433 " xvp610_640x480\n"
434 " ov7620_raw_linear\n"
435 " canon_300d_raw_linear\n"
436 " canon_300d_raw_linear+50mm_1.4\n"
437 " canon_300d_raw_linear+50mm_1.4@1.4\n"
438 " canon_300d_raw_linear+50mm_1.8\n"
439 " canon_300d_raw_linear+85mm_1.8\n"
440 "\n"
443 void exclusion() {
444 banner("Exclusion");
445 fprintf(help_stream,
446 BETWEEN_SECTIONS
447 "Rendering-coordinate exclusion regions:\n"
448 HEADER_SPACE
449 "--ex <args> Exclude a specified volume.\n"
450 " <args> are space-delimited horizontal,\n"
451 " vertical, and frame limits:\n"
452 " <xmin> <xmax> <ymin> <ymax> <fmin> <fmax>\n"
453 " using unscaled rendering spatial coordinates.\n"
454 "--crop <args> Exclude the spatial complement of an area over a\n"
455 " specified set of frames. <args> are:\n"
456 " <xmin> <xmax> <ymin> <ymax> <fmin> <fmax>\n"
457 " using unscaled rendering spatial coordinates.\n"
458 BETWEEN_SECTIONS
459 "Frame-coordinate exclusion regions:\n"
460 HEADER_SPACE
461 "--fex <args> Exclude a specified volume.\n"
462 " <args> are space-delimited horizontal,\n"
463 " vertical, and frame limits:\n"
464 " <xmin> <xmax> <ymin> <ymax> <fmin> <fmax>\n"
465 " using unscaled frame spatial coordinates.\n"
466 "--fcrop <args> Exclude the spatial complement of an area over a\n"
467 " specified set of frames. <args> are:\n"
468 " <xmin> <xmax> <ymin> <ymax> <fmin> <fmax>\n"
469 " using unscaled frame spatial coordinates.\n"
470 "\n"
473 void exposure() {
474 banner("Exposure");
475 fprintf(help_stream,
476 BETWEEN_SECTIONS
477 "Certainty-weighted rendering (see --hq for defaults):\n"
478 HEADER_SPACE
479 "--cx <x> Render with certainty exponent <x>.\n"
480 "--no-cx Render with uniform certainty.\n"
481 BETWEEN_SECTIONS
482 "Options that may be useful when using --cx:\n"
483 "--ips <i> Uses one-sided certainty. (see --hr for details)\n"
484 "--exp-extend Extends the output range. (see below for details)\n"
485 BETWEEN_SECTIONS
486 "Exposure registration:\n"
487 HEADER_SPACE
488 "--exp-register Register exposure between frames. [default]\n"
489 "--exp-noregister Assume uniform exposure across all frames.\n"
490 "--exp-meta-only Use only image metadata for registering exposure.\n"
491 BETWEEN_SECTIONS
492 "Range extension (see --hq for defaults):\n"
493 HEADER_SPACE
494 "--exp-extend Extend range to include all calculated values.\n"
495 "--exp-noextend Restrict to the original frame's range.\n"
496 "\n"
499 void tdf() {
500 banner("Transformation data files");
501 fprintf(help_stream,
502 BETWEEN_SECTIONS
503 "Version 2 syntax overview:\n"
504 HEADER_SPACE
505 "{version string}\n"
506 "{supplemental frame 1 transformation}\n"
507 "{supplemental frame 2 transformation}\n"
508 "...\n"
509 BETWEEN_SECTIONS
510 "Version 3 syntax overview:\n"
511 HEADER_SPACE
512 "{version string}\n"
513 "{original frame transformation}\n"
514 "{supplemental frame 1 transformation}\n"
515 "{supplemental frame 2 transformation}\n"
516 "...\n"
517 BETWEEN_SECTIONS
518 "Version string:\n"
519 HEADER_SPACE
520 "V <x> Transformation data file version <x>.\n"
521 BETWEEN_SECTIONS
522 "Transformation overview:\n"
523 HEADER_SPACE
524 "{barrel/pincushion distortion command (optional; version 3 only)}\n"
525 "{projective, euclidean, or default command}\n"
526 BETWEEN_SECTIONS
527 "Barrel/pincushion distortion (version 3 only):\n"
528 HEADER_SPACE
529 "B <n> <coeff2> <coeff3> ... <coeff(n+1)>\n"
530 BETWEEN_SECTIONS
531 "Projective command:\n"
532 HEADER_SPACE
533 "P <xmax> <ymax> <tlx> <tly> <blx> <bly> <brx> <bry> <trx> <try>\n"
534 BETWEEN_SECTIONS
535 "Euclidean command:\n"
536 HEADER_SPACE
537 "E <xmax> <ymax> <xoffset> <yoffset> <angle>\n"
538 "\n"
539 BETWEEN_SECTIONS
540 "Comments:\n"
541 HEADER_SPACE
542 "# Lines beginning with '#' are comments.\n"
543 BETWEEN_SECTIONS
544 "Example:\n"
545 HEADER_SPACE
546 "# Version 3 transformation data file.\n"
547 "V 3\n"
548 "# Original frame, with barrel/pincushion distortion correction\n"
549 "B 3 0.1 0 -0.1\n"
550 "D\n"
551 "# Supplemental frame 1: shift a 640x480 image right by 100 pixels\n"
552 "E 640 480 100 0 0\n"
553 "\n"
556 void visp() {
557 banner("Video stream processing");
558 fprintf(help_stream,
559 BETWEEN_SECTIONS
560 "Video stream processing [Experimental]:\n"
561 HEADER_SPACE
562 "--visp <args> Process a video sequence.\n"
563 " <args> are:\n"
564 " <chain> <stabilization-type> <prefix> <suffix>\n"
565 " <chain> is an incremental rendering chain. (see --hl)\n"
566 " <stabilization-type> is one of:\n"
567 " ma:<x> Moving average over 2*<x> + 1 frames\n"
568 " sf:<x> Stabilize to single frame number <x>\n"
569 " identity Same as ma:0\n"
570 " <prefix> is an output file prefix\n"
571 " <suffix> is an output file suffix\n"
572 "--visp-scale=<x> Use scale <x> for VISP output. (default is 1.0)\n"
573 "--exshow For single-invariant chains, show --ex regions dimmed.\n"
574 "\n");
576 void interface() {
577 banner("User Interface");
578 fprintf(help_stream,
579 BETWEEN_SECTIONS
580 "User Interfaces:\n"
581 HEADER_SPACE
582 "--ui=<type> Set user interface to <type>, one of:\n"
583 " stream\n"
584 " tty [default]\n"
585 #ifndef USE_IOCTL
586 "\n"
587 " NOTE: since ALE was compiled without terminal size check,\n"
588 " --ui=tty will behave identically to --ui=stream.\n"
589 " For additional output, recompile with terminal size check.\n"
590 #endif
591 "\n");
593 void cp() {
594 banner("Control Points");
595 fprintf(help_stream,
596 BETWEEN_SECTIONS
597 "Control point files:\n"
598 HEADER_SPACE
599 "--cpf-load=<f> Load control point data from file <f>\n"
600 "\n");
602 void d3() {
603 banner("3D Modeling [Experimental]");
604 fprintf(help_stream,
605 BETWEEN_SECTIONS
606 "Rendering:\n"
607 HEADER_SPACE
608 "--3dv <n> <o> Render, to file <o>, colors as viewed from frame <n>.\n"
609 "--3dd <n> <o> Render, to file <o>, depths as viewed from frame <n>.\n"
610 "--3dvp <args> <o> Render, to file <o>, colors viewed with projective <args>.\n"
611 "--3ddp <args> <o> Render, to file <o>, depths viewed with projective <args>.\n"
612 " <args> are W H V x y z P Y R:\n"
613 " W image width.\n"
614 " H image height.\n"
615 " V camera view angle.\n"
616 " x translation x component.\n"
617 " y translation y component.\n"
618 " z translation z component.\n"
619 " P rotation around x-axis.\n"
620 " Y rotation around y-axis.\n"
621 " R rotation around z-axis.\n"
622 "--occ-norm Normalize output with accumulated occupancy. [default]\n"
623 "--occ-nonorm Don't normalize output with accumulated occupancy.\n"
624 "--et <x> Set encounter threshold <x> for defined pixels.[default is 0]\n"
625 "--3dpx <args> Exclude a specified spatial volume following full-scene\n"
626 " reconstruction. <args> are:\n"
627 " <xmin> <xmax> <ymin> <ymax> <zmin> <zmax>\n"
628 "--3d-filter Use filtering for 3D color output. [default]\n"
629 "--3d-nofilter Don't use filtering for 3D color output.\n"
630 "--3d-dmr <x> Set radius for filtering median depth to <x> [default 0]\n"
631 "--3d-fmr <x> Set radius for filtering median diff to <x> [default 0]\n"
632 "--focus <ft> <op> Create focus region with type <ft> and options <op>:\n"
633 " Focus type:\n"
634 " d <d> focus at distance <d>\n"
635 " p <x> <y> focus at point (x, y)\n"
636 " Space-separated options may include zero or more of:\n"
637 " ci=<ci> camera index [default 0]\n"
638 " fr=<fr> focal range [default 0]\n"
639 " ht=<ht> horizontal tilt gradient [default 0]\n"
640 " vt=<vt> vertical tilt gradient [default 0]\n"
641 " ap=<ap> aperture diameter [default 3]\n"
642 " sc=<sc> sample count [default 3]\n"
643 " sx=<sx> start x coordinate [default -Inf]\n"
644 " ex=<ex> end x coordinate [default Inf]\n"
645 " sy=<sy> start y coordinate [default -Inf]\n"
646 " ey=<ey> end y coordinate [default Inf]\n"
647 " sd=<sd> start depth [default 0]\n"
648 " ed=<ed> end depth [default Inf]\n"
649 " sr=<sr> view sample randomization:\n"
650 " aperture per aperture [default]\n"
651 " pixel per pixel\n"
652 " fs=<fs> focal statistic, one of:\n"
653 " mean mean of views [default]\n"
654 " median median of views\n"
655 "\n"
656 BETWEEN_SECTIONS
657 "Camera parameters:\n"
658 HEADER_SPACE
659 "--view-angle <x> Set the initial diagonal view angle to <x> degrees.\n"
660 " (Default is 43.7 degrees or device-specific.)\n"
661 "--cpp-upper=<x> Set upper bound <x> for camera parameter perturbation,\n"
662 " in pixels or degrees [default is 32]\n"
663 "--cpp-lower=<x> Set lower bound <x> for camera parameter perturbation,\n"
664 " in pixels or degrees [default is 0.125]\n"
665 "--cpp-err-mean Use RMS error to determine camera parameters. [default]\n"
666 "--cpp-err-median Use median error to determine camera parameters. \n"
667 "--va-upper=<x> View-angle perturbation upper bound in degrees [default 32]\n"
668 "--st <x> Set stereo threshold to <x> pixels. [default is 4]\n"
669 "--vp-adjust Adjust the view point [default]\n"
670 "--vp-noadjust Do not adjust the view point\n"
671 "--vo-adjust Adjust the view orientation [default]\n"
672 "--vo-noadjust Do not adjust the view orientation\n"
673 BETWEEN_SECTIONS
674 "Transformation file operations:\n"
675 HEADER_SPACE
676 "--3d-trans-load=x Load initial transformation settings from file x\n"
677 "--3d-trans-save=x Save final transformation data in file x\n"
678 BETWEEN_SECTIONS
679 "Model rules:\n"
680 HEADER_SPACE
681 "--di-upper <x> Decimate primary input resolution by at most 2^x [default 0]\n"
682 "--di-lower <x> Decimate input resolutions by at least 2^x [default is 0]\n"
683 "--do-try <x> Decimate output resolution by 2^x if possible [default is 0]\n"
684 "--oc Clip scene to output regions.\n"
685 "--no-oc Do not clip scene to output regions. [default]\n"
686 "--fc <x> Set front-clip to <x> (0 < x < 1) [default is 0]\n"
687 "--rc <x> Set rear-clip to <x> (1 < x < inf) [default is inf]\n"
688 "--fx <x> Set falloff exponent to <x> [default is 1]\n"
689 "--tcem <x> Set third-camera error multiplier to <x> [default is 0]\n"
690 "--oui <x> Set occupancy update iterations to <x> [default is 10]\n"
691 "--pa <x> Set pairwise ambiguity to <x> [default is 3]\n"
692 "--pc <type> Set the type of pairwise comparisons:\n"
693 " auto Determine comparisons automatically. [default]\n"
694 " all Perform all comparisons.\n"
695 "\n");
697 void scope() {
698 banner("Argument scope [experimental]");
699 fprintf(help_stream,
700 BETWEEN_SECTIONS
701 "List of arguments admitting scoping:\n"
702 HEADER_SPACE
703 "--mc (see --ha for more details)\n"
704 "--mcd-removal (see --ha for more details)\n"
705 "--threads (see --hp for more details)\n"
706 "--per-cpu (see --hp for more details)\n"
707 "--perturb-upper (see --ha for more details)\n"
708 BETWEEN_SECTIONS
709 "Implicit file scope (implementation may be buggy):\n"
710 HEADER_SPACE
711 "arg1 file1 arg2 <arg2> applies only to files later than <file1>.\n"
712 " Example:\n"
713 "\n"
714 " --mc 10 file1 --mc 20 file2\n"
715 "\n"
716 " (file1 has monte-carlo argument 10; file2 has --mc 20.)\n"
717 "\n"
718 BETWEEN_SECTIONS
719 "Hidden scope (implementation may be buggy):\n"
720 HEADER_SPACE
721 "[ args ] Hide the effects of <args> options within [ ... ] scope\n"
722 " Example:\n"
723 "\n"
724 " file1 [ --mc 20 file2 ] file3\n"
725 "\n"
726 " (The monte-carlo argument is limited to file2.)\n"
727 "\n"
728 BETWEEN_SECTIONS
729 "Exposed scope (implementation may be buggy):\n"
730 HEADER_SPACE
731 "[ arg1 < arg2 > ] Expose the effects of <arg2> outside of [ ... ] scope\n"
732 BETWEEN_SECTIONS
733 "Fully-exposed scope (implementation may be buggy):\n"
734 HEADER_SPACE
735 "{ arg1 } Same as [ < arg1 > ].\n"
736 "\n");
738 void process() {
739 banner("Process details");
740 fprintf(help_stream,
741 BETWEEN_SECTIONS
742 "Profiling:\n"
743 HEADER_SPACE
744 "--profile Output performance data\n"
745 BETWEEN_SECTIONS
746 "Thread count:\n"
747 "\n"
748 " If the CPU count cannot be determined, the default thread count\n"
749 " is 4. Otherwise, the default is one thread per CPU.\n"
750 "\n"
751 HEADER_SPACE
752 "--threads <n> Use <n> threads.\n"
753 #ifndef USE_PTHREAD
754 "\n"
755 " NOTE: since this build of ALE does not link with a\n"
756 " threading library, this option is not supported.\n"
757 " To use this option, first rebuild with support\n"
758 " for threads.\n"
759 "\n"
760 #endif
761 "--per-cpu <n> Use <n> threads for each detected CPU.\n"
762 #ifndef USE_PTHREAD
763 "\n"
764 " NOTE: since this build of ALE does not link with a\n"
765 " threading library, this option is not supported.\n"
766 " To use this option, first rebuild with support\n"
767 " for threads.\n"
768 "\n"
769 #endif
770 "\n");
772 void undocumented() {
773 banner("Undocumented");
774 fprintf(help_stream,
775 BETWEEN_SECTIONS
776 "Point-spread functions:\n"
777 HEADER_SPACE
778 "--psf-match <args> Can be used to evaluate PSFs. [details are undocumented]\n"
779 " <args> are:\n"
780 " <mr> <mg> <mb> <ar> <ag> <ab>\n"
781 " where:\n"
782 " r[calibrated] = r[input] * <mr> + <ar>\n"
783 BETWEEN_SECTIONS
784 "Projective transformation calculator:\n"
785 HEADER_SPACE
786 "--ptcalc\n"
787 BETWEEN_SECTIONS
788 "Traverse subspaces for 3D candidate selection:\n"
789 HEADER_SPACE
790 "--subspace-traverse\n"
791 "\n"
796 #undef BETWEEN_SECTIONS
797 #undef HEADER_SPACE