| 1 | package Panotools::Script::Line::Mode; | ||||||||||
| 2 | |||||||||||
| 3 | 11 | ▶ | use strict; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 4 | 11 | ▶ | use warnings; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 5 | 11 | ▶ | use Panotools::Script::Line; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 6 | |||||||||||
| 7 | 11 | ▶ | use vars qw /@ISA/; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 8 | 11 | @ISA = qw /Panotools::Script::Line/; | |||||||||
| 9 | |||||||||||
| 10 | =head1 NAME | ||||||||||
| 11 | |||||||||||
| 12 | Panotools::Script::Line::Mode - Panotools stitching mode | ||||||||||
| 13 | |||||||||||
| 14 | =head1 SYNOPSIS | ||||||||||
| 15 | |||||||||||
| 16 | Optional stitching modes are described by an 'm' line | ||||||||||
| 17 | |||||||||||
| 18 | =head1 DESCRIPTION | ||||||||||
| 19 | |||||||||||
| 20 | m i2 | ||||||||||
| 21 | |||||||||||
| 22 | g2.5 Set gamma value for internal computations (default 1.0) | ||||||||||
| 23 | See <http://www.fh-furtwangen.de/~dersch/gamma/gamma.html> | ||||||||||
| 24 | This is especially useful in conjunction with the vignetting correction | ||||||||||
| 25 | by division | ||||||||||
| 26 | |||||||||||
| 27 | i2 Set interpolator, See <http://www.fh-furtwangen.de/~dersch/interpolator/interpolator.html> | ||||||||||
| 28 | one of: | ||||||||||
| 29 | 0 - poly3 (default) | ||||||||||
| 30 | 1 - spline16, | ||||||||||
| 31 | 2 - spline36, | ||||||||||
| 32 | 3 - sinc256, | ||||||||||
| 33 | 4 - spline64, | ||||||||||
| 34 | 5 - bilinear, | ||||||||||
| 35 | 6 - nearest neighbor, | ||||||||||
| 36 | 7 - sinc1024 | ||||||||||
| 37 | |||||||||||
| 38 | m2 Huber Sigma | ||||||||||
| 39 | |||||||||||
| 40 | p0.001 Photometric Huber Sigma | ||||||||||
| 41 | |||||||||||
| 42 | s1 Photometric Symmetric Error | ||||||||||
| 43 | |||||||||||
| 44 | =cut | ||||||||||
| 45 | |||||||||||
| 46 | sub _defaults | ||||||||||
| 47 | 17 | ▶ | { | ||||||||
|
Subroutine
_defaults: called CC=1 SCAR=0.0
| |||||||||||
| 48 | 17 | my $self = shift; | |||||||||
| 49 | 17 | $self->{g} = 1.0; | |||||||||
| 50 | 17 | $self->{i} = 0; | |||||||||
| 51 | 17 | $self->{m} = 2; | |||||||||
| 52 | 17 | $self->{p} = 0.00784314; | |||||||||
| 53 | } | ||||||||||
| 54 | |||||||||||
| 55 | 26 | ▶ | sub _valid { return '^([fgimps])(.*)' } | ||||||||
|
Subroutine
_valid: called CC=1 SCAR=0.0
| |||||||||||
| 56 | |||||||||||
| 57 | sub Identifier | ||||||||||
| 58 | 12 | ▶ | { | ||||||||
|
Subroutine
Identifier: called CC=1 SCAR=0.0
Pod
undocumented
| |||||||||||
| 59 | 12 | my $self = shift; | |||||||||
| 60 | 12 | return "m"; | |||||||||
| 61 | } | ||||||||||
| 62 | |||||||||||
| 63 | sub Report | ||||||||||
| 64 | 1 | ▶ | { | ||||||||
|
Subroutine
Report: called CC=14 SCAR=29.7
Pod
undocumented
| |||||||||||
| 65 | 1 | my $self = shift; | |||||||||
| 66 | 1 | my @report; | |||||||||
| 67 | |||||||||||
| 68 | 1 | my $interpolator = 'UNKNOWN'; | |||||||||
| 69 | 1 | ▶ | $interpolator = 'poly3' if $self->{i} == 0; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 70 | 1 | ▶ | $interpolator = 'spline16' if $self->{i} == 1; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 71 | 1 | ▶ | $interpolator = 'spline36' if $self->{i} == 2; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 72 | 1 | ▶ | $interpolator = 'sinc256' if $self->{i} == 3; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 73 | 1 | ▶ | $interpolator = 'spline64' if $self->{i} == 4; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 74 | 1 | ▶ | $interpolator = 'bilinear' if $self->{i} == 5; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 75 | 1 | ▶ | $interpolator = 'nearest neighbor' if $self->{i} == 6; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 76 | 1 | ▶ | $interpolator = 'sinc1024' if $self->{i} == 7; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 77 | |||||||||||
| 78 | 1 | ▶ | push @report, ['Gamma', $self->{g}] if defined $self->{g}; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 79 | 1 | ▶ | push @report, ['Interpolator', $interpolator] if defined $self->{i}; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 80 | 1 | ▶ | push @report, ['Huber Sigma', $self->{m}] if defined $self->{m}; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 81 | 1 | ▶ | push @report, ['Photometric Huber Sigma', $self->{p}] if defined $self->{p}; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 82 | 1 | ▶ | push @report, ['Photometric Symmetric Error', $self->{s}] if defined $self->{s}; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 83 | 1 | [@report]; | |||||||||
| 84 | } | ||||||||||
| 85 | |||||||||||
| 86 | 11 | 1; | |||||||||