Isis 3 Developer Reference
Isis::LroWideAngleCameraFocalPlaneMap Class Reference

Distort/undistort focal plane coordinates. More...

#include <LroWideAngleCameraFocalPlaneMap.h>

Inheritance diagram for Isis::LroWideAngleCameraFocalPlaneMap:
Inheritance graph
Collaboration diagram for Isis::LroWideAngleCameraFocalPlaneMap:
Collaboration graph

Public Types

enum  FocalPlaneXDependencyType { Sample = 1, Line = 2 }
 Focal plane x dependency indicates whether the x value of the focal plane coordinate maps to a sample or a line. More...
 

Public Member Functions

 LroWideAngleCameraFocalPlaneMap (Camera *parent, int naifIkCode)
 Camera distortion map constructor. More...
 
virtual ~LroWideAngleCameraFocalPlaneMap ()
 Destroys the LroWideAngleCameraFocalPlaneMap object. More...
 
void addFilter (int naifIkCode)
 Add an additional set of parameters for a given LROC/WAC filter. More...
 
void setBand (int vband)
 Implements band-dependant focal plane parameters. More...
 
virtual bool SetDetector (const double sample, const double line)
 Compute distorted focal plane coordinate from detector position (sampel,line) More...
 
virtual bool SetFocalPlane (const double dx, const double dy)
 Compute detector position (sample,line) from focal plane coordinates. More...
 
double FocalPlaneX () const
 
double FocalPlaneY () const
 
double DetectorSample () const
 
double DetectorLine () const
 
double CenteredDetectorSample () const
 
double CenteredDetectorLine () const
 
void SetDetectorOrigin (const double sample, const double line)
 Set the detector origin. More...
 
double DetectorLineOrigin () const
 
double DetectorSampleOrigin () const
 
void SetDetectorOffset (const double sampleOffset, const double lineOffset)
 Set the detector offset. More...
 
double DetectorLineOffset () const
 
double DetectorSampleOffset () const
 
void SetTransL (const QVector< double > transL)
 Set the affine coefficients for converting destorted (x,y) to a detector Line. More...
 
void SetTransS (const QVector< double > transS)
 Set the affine coefficients for converting destorted (x,y) to a detector Sample. More...
 
void SetTransX (const QVector< double > transX)
 Set the affine coefficients for converting detector (sample,line) to a distorted X. More...
 
void SetTransY (const QVector< double > transY)
 Set the affine coefficients for converting detector (sample,line) to a distorted Y. More...
 
const double * TransL () const
 
const double * TransS () const
 
const double * TransX () const
 
const double * TransY () const
 
int FocalPlaneXDependency ()
 Return the focal plane x dependency variable. More...
 
double SignMostSigX ()
 Return the sign of the p_transx coefficient with the greatest magnitude. More...
 
double SignMostSigY ()
 Return the sign of the p_transy coefficient with the greatest magnitude. More...
 

Protected Member Functions

void ComputeCentered ()
 Convenience method to center detector origin (use when inheriting) More...
 
void ComputeUncentered ()
 Convenience method to center detector origin (use when inheriting) More...
 

Protected Attributes

Camerap_camera
 Camera of the image. More...
 
double p_detectorLineOrigin
 The origin line of the detector. More...
 
double p_detectorSampleOrigin
 The origin sample of the detector. More...
 
double p_focalPlaneX
 x value of focal plane coordinate More...
 
double p_focalPlaneY
 y value of focal plane coordinate More...
 
double p_detectorLine
 line value of the detector More...
 
double p_detectorSample
 sample value of the detector More...
 
double p_centeredDetectorSample
 Detector sample position. More...
 
double p_centeredDetectorLine
 Detector line position. More...
 
double p_detectorLineOffset
 Offset of the detector origin line from the average. More...
 
double p_detectorSampleOffset
 offset of the detector origin sample from the average More...
 
double p_transx [3]
 The x transition from detector to distorted. More...
 
double p_transy [3]
 The y transition from detector to distorted. More...
 
double p_itranss [3]
 The x transition from distorted to detector. More...
 
double p_itransl [3]
 The y transition from distorted to detector. More...
 

Detailed Description

Distort/undistort focal plane coordinates.

Creates a map for adding/removing optical distortions from the focal plane of a camera.

See also
LroWideAngleCamera
Author
2013-03-07 Kris Becker

Member Enumeration Documentation

◆ FocalPlaneXDependencyType

Focal plane x dependency indicates whether the x value of the focal plane coordinate maps to a sample or a line.

Enumerator
Sample 

The x value of the focal plane maps to a sample.

Line 

The x value of the focal plane maps to a line.

Constructor & Destructor Documentation

◆ LroWideAngleCameraFocalPlaneMap()

Isis::LroWideAngleCameraFocalPlaneMap::LroWideAngleCameraFocalPlaneMap ( Camera parent,
int  naifIkCode 
)

Camera distortion map constructor.

Create a camera distortion map. This class maps between distorted and undistorted focal plane x/y's. The default mapping is the identity, that is, the focal plane x/y and undistorted focal plane x/y will be identical.

Parameters
parentthe parent camera that will use this distortion map
zDirectionthe direction of the focal plane Z-axis (either 1 or -1)

◆ ~LroWideAngleCameraFocalPlaneMap()

virtual Isis::LroWideAngleCameraFocalPlaneMap::~LroWideAngleCameraFocalPlaneMap ( )
inlinevirtual

Destroys the LroWideAngleCameraFocalPlaneMap object.

Member Function Documentation

◆ addFilter()

void Isis::LroWideAngleCameraFocalPlaneMap::addFilter ( int  naifIkCode)

Add an additional set of parameters for a given LROC/WAC filter.

This method will read the parameters for LROC/WAC filter as indicated by the IK code provided. It will create a vector of these parameters and append them to the band list.

The filters added should correspond directly to the order in which the filters are physically stored in the ISIS cube (or the virtually selected bands).

Author
2013-03-07 Kris Becker
Parameters
naifIkCodeNAIF IK code for the desired filter to add.

References Isis::Spice::getDouble(), Isis::CameraFocalPlaneMap::p_camera, and Isis::toString().

Referenced by Isis::LroWideAngleCamera::LroWideAngleCamera().

◆ CenteredDetectorLine()

double Isis::CameraFocalPlaneMap::CenteredDetectorLine ( ) const
inherited
Returns
The centered detector line

References Isis::CameraFocalPlaneMap::p_centeredDetectorLine.

◆ CenteredDetectorSample()

double Isis::CameraFocalPlaneMap::CenteredDetectorSample ( ) const
inherited
Returns
The centered detector sample

References Isis::CameraFocalPlaneMap::p_centeredDetectorSample.

◆ ComputeCentered()

◆ ComputeUncentered()

◆ DetectorLine()

◆ DetectorLineOffset()

double Isis::CameraFocalPlaneMap::DetectorLineOffset ( ) const
inherited

◆ DetectorLineOrigin()

double Isis::CameraFocalPlaneMap::DetectorLineOrigin ( ) const
inherited

◆ DetectorSample()

◆ DetectorSampleOffset()

double Isis::CameraFocalPlaneMap::DetectorSampleOffset ( ) const
inherited
Returns
The detector sample offset

References Isis::CameraFocalPlaneMap::p_detectorSampleOffset.

◆ DetectorSampleOrigin()

double Isis::CameraFocalPlaneMap::DetectorSampleOrigin ( ) const
inherited

◆ FocalPlaneX()

double Isis::CameraFocalPlaneMap::FocalPlaneX ( ) const
inherited

◆ FocalPlaneXDependency()

int Isis::CameraFocalPlaneMap::FocalPlaneXDependency ( )
inherited

Return the focal plane x dependency variable.

This method returns the image variable (sample or line) on which the focal plane x depends.

Returns
dependency variable

References Isis::CameraFocalPlaneMap::Line, Isis::CameraFocalPlaneMap::p_transx, and Isis::CameraFocalPlaneMap::Sample.

◆ FocalPlaneY()

double Isis::CameraFocalPlaneMap::FocalPlaneY ( ) const
inherited

◆ setBand()

void Isis::LroWideAngleCameraFocalPlaneMap::setBand ( int  vband)

Implements band-dependant focal plane parameters.

This method should be used to switch to another band's set of distortion parameters. See the addFilter() method to add additional band parameters to this object. Note that the band number should correspond with the same order as they were added in the addFilter() method.

Author
2013-03-07 Kris Becker
Parameters
vbandBand number to select. Range is 1 to Bands.

References _FILEINFO_, Isis::CameraFocalPlaneMap::p_itransl, Isis::CameraFocalPlaneMap::p_itranss, Isis::CameraFocalPlaneMap::p_transx, Isis::CameraFocalPlaneMap::p_transy, and Isis::IException::Programmer.

Referenced by Isis::LroWideAngleCamera::SetBand().

◆ SetDetector()

bool Isis::CameraFocalPlaneMap::SetDetector ( const double  sample,
const double  line 
)
virtualinherited

Compute distorted focal plane coordinate from detector position (sampel,line)

This method will compute both the distorted focal plane x/y and centered detector position given a detector position

Parameters
sampleundistorted focal plane x in millimeters
lineundistorted focal plane y in millimeters
Returns
conversion was successful

References Isis::CameraFocalPlaneMap::ComputeCentered(), Isis::CameraFocalPlaneMap::p_centeredDetectorLine, Isis::CameraFocalPlaneMap::p_centeredDetectorSample, Isis::CameraFocalPlaneMap::p_detectorLine, Isis::CameraFocalPlaneMap::p_detectorSample, Isis::CameraFocalPlaneMap::p_focalPlaneX, Isis::CameraFocalPlaneMap::p_focalPlaneY, Isis::CameraFocalPlaneMap::p_transx, and Isis::CameraFocalPlaneMap::p_transy.

Referenced by Isis::LoMediumDistortionMap::SetFocalPlane(), Isis::Camera::SetImage(), and Isis::LoMediumDistortionMap::SetUndistortedFocalPlane().

◆ SetDetectorOffset()

void Isis::CameraFocalPlaneMap::SetDetectorOffset ( const double  sampleOffset,
const double  lineOffset 
)
inherited

◆ SetDetectorOrigin()

void Isis::CameraFocalPlaneMap::SetDetectorOrigin ( const double  sample,
const double  line 
)
inherited

Set the detector origin.

This is used to set the origin of the detector. Typically the middle of the detector. For example, a 512x512 dectector would have the origin at (256.5,256.5). If not set both are 0.

Parameters
sampledetector sample at the origin
linedetector line at the origin

References Isis::CameraFocalPlaneMap::p_detectorLineOrigin, and Isis::CameraFocalPlaneMap::p_detectorSampleOrigin.

Referenced by Isis::ApolloMetricCamera::ApolloMetricCamera(), Isis::ApolloPanoramicCamera::ApolloPanoramicCamera(), Isis::Chandrayaan1M3Camera::Chandrayaan1M3Camera(), Isis::CrismCamera::CrismCamera(), Isis::CTXCamera::CTXCamera(), Isis::DawnFcCamera::DawnFcCamera(), Isis::DawnVirCamera::DawnVirCamera(), Isis::HayabusaAmicaCamera::HayabusaAmicaCamera(), Isis::HayabusaNirsCamera::HayabusaNirsCamera(), Isis::HiresCamera::HiresCamera(), Isis::HiriseCamera::HiriseCamera(), Isis::HrscCamera::HrscCamera(), Isis::Hyb2OncCamera::Hyb2OncCamera(), Isis::IdealCamera::IdealCamera(), Isis::IssNACamera::IssNACamera(), Isis::IssWACamera::IssWACamera(), Isis::JunoCamera::JunoCamera(), Isis::KaguyaMiCamera::KaguyaMiCamera(), Isis::KaguyaTcCamera::KaguyaTcCamera(), Isis::LoHighCamera::LoHighCamera(), Isis::LoMediumCamera::LoMediumCamera(), Isis::LroNarrowAngleCamera::LroNarrowAngleCamera(), Isis::LwirCamera::LwirCamera(), Isis::MarciCamera::MarciCamera(), Isis::Mariner10Camera::Mariner10Camera(), Isis::MdisCamera::MdisCamera(), Isis::MocNarrowAngleCamera::MocNarrowAngleCamera(), Isis::MocWideAngleCamera::MocWideAngleCamera(), Isis::MsiCamera::MsiCamera(), Isis::NewHorizonsLeisaCamera::NewHorizonsLeisaCamera(), Isis::NewHorizonsLorriCamera::NewHorizonsLorriCamera(), Isis::NewHorizonsMvicFrameCamera::NewHorizonsMvicFrameCamera(), Isis::NewHorizonsMvicTdiCamera::NewHorizonsMvicTdiCamera(), Isis::NirCamera::NirCamera(), Isis::OsirisRexOcamsCamera::OsirisRexOcamsCamera(), Isis::RosettaOsirisCamera::RosettaOsirisCamera(), Isis::RosettaVirtisCamera::RosettaVirtisCamera(), Isis::ThemisIrCamera::SetBand(), Isis::LroWideAngleCamera::SetBand(), Isis::SsiCamera::SsiCamera(), Isis::TgoCassisCamera::TgoCassisCamera(), Isis::ThemisIrCamera::ThemisIrCamera(), Isis::ThemisVisCamera::ThemisVisCamera(), Isis::UvvisCamera::UvvisCamera(), Isis::VikingCamera::VikingCamera(), and Isis::VoyagerCamera::VoyagerCamera().

◆ SetFocalPlane()

bool Isis::CameraFocalPlaneMap::SetFocalPlane ( const double  dx,
const double  dy 
)
virtualinherited

Compute detector position (sample,line) from focal plane coordinates.

NOTE: This is detector (sample, line) not necessarily image (sample, line). If the image was reformatted from what was collected the two differ. See the New Horizons LEISA camera for an example (LEISA is a frame camera being treated as a line scan camera).

This method will compute both the centered and normal detector position given a distorted focal plane coordinate.

Parameters
dxdistorted focal plane x in millimeters
dydistorted focal plane y in millimeters
Returns
conversion was successful

References Isis::CameraFocalPlaneMap::ComputeUncentered(), Isis::CameraFocalPlaneMap::p_centeredDetectorLine, Isis::CameraFocalPlaneMap::p_centeredDetectorSample, Isis::CameraFocalPlaneMap::p_focalPlaneX, Isis::CameraFocalPlaneMap::p_focalPlaneY, Isis::CameraFocalPlaneMap::p_itransl, and Isis::CameraFocalPlaneMap::p_itranss.

Referenced by Isis::ControlPoint::ComputeResiduals(), Isis::LoMediumDistortionMap::SetDistortion(), Isis::LoMediumDistortionMap::SetFocalPlane(), Isis::Camera::SetRightAscensionDeclination(), Isis::LineScanCameraSkyMap::SetSky(), and Isis::LoMediumDistortionMap::SetUndistortedFocalPlane().

◆ SetTransL()

void Isis::CameraFocalPlaneMap::SetTransL ( const QVector< double >  transL)
inherited

Set the affine coefficients for converting destorted (x,y) to a detector Line.

Parameters
transLVector of the affine coefficients

References Isis::CameraFocalPlaneMap::p_itransl.

Referenced by Isis::NewHorizonsLeisaCamera::SetBand().

◆ SetTransS()

void Isis::CameraFocalPlaneMap::SetTransS ( const QVector< double >  transS)
inherited

Set the affine coefficients for converting destorted (x,y) to a detector Sample.

Parameters
transSVector of the affine coefficients

References Isis::CameraFocalPlaneMap::p_itranss.

Referenced by Isis::NewHorizonsLeisaCamera::SetBand().

◆ SetTransX()

void Isis::CameraFocalPlaneMap::SetTransX ( const QVector< double >  transX)
inherited

Set the affine coefficients for converting detector (sample,line) to a distorted X.

Parameters
transXVector of the affine coefficients

References Isis::CameraFocalPlaneMap::p_transx.

Referenced by Isis::NewHorizonsLeisaCamera::SetBand().

◆ SetTransY()

void Isis::CameraFocalPlaneMap::SetTransY ( const QVector< double >  transY)
inherited

Set the affine coefficients for converting detector (sample,line) to a distorted Y.

Parameters
transYVector of the affine coefficients

References Isis::CameraFocalPlaneMap::p_transy.

Referenced by Isis::NewHorizonsLeisaCamera::SetBand().

◆ SignMostSigX()

double Isis::CameraFocalPlaneMap::SignMostSigX ( )
inherited

Return the sign of the p_transx coefficient with the greatest magnitude.

This method returns a +1. or -1. based on the sign of the p_transx coefficient with the greatest magnitude. Only p_transx[1] and p_transx[2] are compared since p_transx[0] is used as a constant in the affine transformation.

Returns
sign of most significant coefficient

References Isis::CameraFocalPlaneMap::p_transx.

◆ SignMostSigY()

double Isis::CameraFocalPlaneMap::SignMostSigY ( )
inherited

Return the sign of the p_transy coefficient with the greatest magnitude.

This method returns a +1 or -1 based on the sign of the p_transy coefficient with the greatest magnitude. Only p_transy[1] and p_transy[2] are compared since p_transy[0] is used as a constant in the affine transformation.

Returns
sign of most significant coefficient

References Isis::CameraFocalPlaneMap::p_transy.

◆ TransL()

const double * Isis::CameraFocalPlaneMap::TransL ( ) const
inherited
Returns
The affine coefficients for converting distorted (x,y) to a detector Line

References Isis::CameraFocalPlaneMap::p_itransl.

Referenced by Isis::NewHorizonsLeisaCamera::NewHorizonsLeisaCamera().

◆ TransS()

const double * Isis::CameraFocalPlaneMap::TransS ( ) const
inherited
Returns
The affine coefficients for converting distorted (x,y) to a detector Sample

References Isis::CameraFocalPlaneMap::p_itranss.

Referenced by Isis::NewHorizonsLeisaCamera::NewHorizonsLeisaCamera().

◆ TransX()

const double * Isis::CameraFocalPlaneMap::TransX ( ) const
inherited
Returns
The affine coefficients for converting detector (sample,line) to a distorted X

References Isis::CameraFocalPlaneMap::p_transx.

Referenced by Isis::NewHorizonsLeisaCamera::NewHorizonsLeisaCamera().

◆ TransY()

const double * Isis::CameraFocalPlaneMap::TransY ( ) const
inherited
Returns
The affine coefficients for converting detector (sample,line) to distorted Y

References Isis::CameraFocalPlaneMap::p_transy.

Referenced by Isis::NewHorizonsLeisaCamera::NewHorizonsLeisaCamera().

Member Data Documentation

◆ p_camera

Camera* Isis::CameraFocalPlaneMap::p_camera
protectedinherited

◆ p_centeredDetectorLine

◆ p_centeredDetectorSample

◆ p_detectorLine

double Isis::CameraFocalPlaneMap::p_detectorLine
protectedinherited

◆ p_detectorLineOffset

double Isis::CameraFocalPlaneMap::p_detectorLineOffset
protectedinherited

◆ p_detectorLineOrigin

◆ p_detectorSample

double Isis::CameraFocalPlaneMap::p_detectorSample
protectedinherited

◆ p_detectorSampleOffset

double Isis::CameraFocalPlaneMap::p_detectorSampleOffset
protectedinherited

◆ p_detectorSampleOrigin

◆ p_focalPlaneX

double Isis::CameraFocalPlaneMap::p_focalPlaneX
protectedinherited

◆ p_focalPlaneY

double Isis::CameraFocalPlaneMap::p_focalPlaneY
protectedinherited

◆ p_itransl

double Isis::CameraFocalPlaneMap::p_itransl[3]
protectedinherited

◆ p_itranss

double Isis::CameraFocalPlaneMap::p_itranss[3]
protectedinherited

◆ p_transx

◆ p_transy

double Isis::CameraFocalPlaneMap::p_transy[3]
protectedinherited

The documentation for this class was generated from the following files: