USGS

Isis 3.0 Developer's Reference (API)

Home

Isis::ControlPoint Class Reference

A single control point. More...

#include <ControlPoint.h>

Inherits QObject.

Classes

struct  RadiusSource
 
struct  SurfacePointSource
 

Public Types

enum  PointType { Fixed = 0, Constrained = 1, Free = 2 }
 These are the valid 'types' of point. More...
 
enum  Status { Failure, Success, PointLocked }
 This is a return status for many of the mutating (setter) method calls. More...
 
enum  ConstraintStatus { LatitudeConstrained = 0, LongitudeConstrained = 1, RadiusConstrained = 2 }
 This is a convenience member for checking number of constrained coordinates in the SurfacePoint. More...
 

Public Member Functions

 ControlPoint ()
 Construct a control point.
 
 ControlPoint (const ControlPoint &)
 Copy the given control point into this instance.
 
 ControlPoint (const QString &id)
 Construct a control point with given Id.
 
 ControlPoint (const ControlPointFileEntryV0002 &fileEntry, const Distance &majorRad, const Distance &minorRad, const Distance &polarRad)
 This is used when reading from a protocol buffer.
 
 ~ControlPoint ()
 This destroys the current instance and cleans up any and all allocated memory.
 
ControlNetParent ()
 
void Load (PvlObject &p)
 Loads the PvlObject into a ControlPoint.
 
void Add (ControlMeasure *measure)
 Add a measurement to the control point, taking ownership of the measure in the process.
 
int Delete (ControlMeasure *measure)
 Remove a measurement from the control point, deleting reference measure is allowed.
 
int Delete (QString serialNumber)
 Remove a measurement from the control point, deleting reference measure is allowed.
 
int Delete (int index)
 Remove a measurement from the control point, deleting reference measure is allowed.
 
Status ResetApriori ()
 Reset all the Apriori info to defaults.
 
const ControlMeasureGetMeasure (QString serialNumber) const
 Get a control measure based on its cube's serial number.
 
ControlMeasureGetMeasure (QString serialNumber)
 Get a control measure based on its cube's serial number.
 
const ControlMeasureGetMeasure (int index) const
 
ControlMeasureGetMeasure (int index)
 
const ControlMeasureGetRefMeasure () const
 Get the reference control measure.
 
ControlMeasureGetRefMeasure ()
 Get the measure that is the reference directly.
 
Status SetChooserName (QString name)
 Set the point's chooser name.
 
Status SetDateTime (QString newDateTime)
 Set the point's last modified time.
 
Status SetEditLock (bool editLock)
 Set the EditLock state.
 
Status SetId (QString id)
 Sets the Id of the control point.
 
Status SetRefMeasure (ControlMeasure *cm)
 Set the point's reference measure.
 
Status SetRefMeasure (int index)
 Set the point's reference measure.
 
Status SetRefMeasure (QString sn)
 Set the points reference measure.
 
Status SetRejected (bool rejected)
 Set the jigsawRejected state.
 
Status SetIgnored (bool newIgnoreStatus)
 Set whether to ignore or use control point.
 
Status SetAdjustedSurfacePoint (SurfacePoint newSurfacePoint)
 Set or update the surface point relating to this control point.
 
Status SetType (PointType newType)
 Updates the control point's type.
 
Status SetAprioriRadiusSource (RadiusSource::Source source)
 This updates the source of the radius of the apriori surface point.
 
Status SetAprioriRadiusSourceFile (QString sourceFile)
 This updates the filename of the DEM that the apriori radius came from.
 
Status SetAprioriSurfacePoint (SurfacePoint aprioriSP)
 This updates the apriori surface point.
 
Status SetAprioriSurfacePointSource (SurfacePointSource::Source source)
 This updates the source of the surface point.
 
Status SetAprioriSurfacePointSourceFile (QString sourceFile)
 This updates the filename of where the apriori surface point came from.
 
Status ComputeApriori ()
 This method computes the apriori lat/lon for a point.
 
Status ComputeResiduals ()
 This method computes the BundleAdjust residuals for a point.
 
Status ComputeResiduals_Millimeters ()
 This method computes the residuals for a point.
 
SurfacePoint GetAdjustedSurfacePoint () const
 
SurfacePoint GetBestSurfacePoint () const
 Returns the adjusted surface point if it exists, otherwise returns the a priori surface point.
 
QString GetChooserName () const
 
QString GetDateTime () const
 
bool IsEditLocked () const
 
bool IsRejected () const
 
QString GetId () const
 Return the Id of the control point.
 
bool IsIgnored () const
 
bool IsValid () const
 
bool IsInvalid () const
 
bool IsFixed () const
 
bool HasAprioriCoordinates ()
 
bool IsConstrained ()
 
bool IsLatitudeConstrained ()
 
bool IsLongitudeConstrained ()
 
bool IsRadiusConstrained ()
 
int NumberOfConstrainedCoordinates ()
 
QString GetPointTypeString () const
 Obtain a string representation of the PointType.
 
PointType GetType () const
 
QString GetRadiusSourceString () const
 Obtain a string representation of the RadiusSource.
 
QString GetSurfacePointSourceString () const
 Obtain a string representation of the SurfacePointSource.
 
SurfacePoint GetAprioriSurfacePoint () const
 
RadiusSource::Source GetAprioriRadiusSource () const
 
QString GetAprioriRadiusSourceFile () const
 
SurfacePointSource::Source GetAprioriSurfacePointSource () const
 
QString GetAprioriSurfacePointSourceFile () const
 
int GetNumMeasures () const
 
int GetNumValidMeasures () const
 
int GetNumLockedMeasures () const
 Returns the number of locked control measures.
 
bool HasSerialNumber (QString serialNumber) const
 Return true if given serial number exists in point.
 
int IndexOf (ControlMeasure *, bool throws=true) const
 
int IndexOf (QString sn, bool throws=true) const
 
int IndexOfRefMeasure () const
 
bool IsReferenceExplicit () const
 
QString GetReferenceSN () const
 
Statistics GetStatistic (double(ControlMeasure::*statFunc)() const) const
 This function will call a given method on every control measure that this point has.
 
Statistics GetStatistic (long dataType) const
 
QList< ControlMeasure * > getMeasures (bool excludeIgnored=false) const
 
QList< QString > getCubeSerialNumbers () const
 
const ControlMeasureoperator[] (QString serialNumber) const
 Same as GetMeasure (provided for convenience)
 
ControlMeasureoperator[] (QString serialNumber)
 Same as GetMeasure (provided for convenience)
 
const ControlMeasureoperator[] (int index) const
 Same as GetMeasure (provided for convenience)
 
ControlMeasureoperator[] (int index)
 Same as GetMeasure (provided for convenience)
 
bool operator!= (const ControlPoint &pPoint) const
 Compare two Control Points for inequality.
 
bool operator== (const ControlPoint &pPoint) const
 Compare two Control Points for equality.
 
const ControlPointoperator= (const ControlPoint &pPoint)
 
void ZeroNumberOfRejectedMeasures ()
 Initialize the number of rejected measures to 0.
 
void SetNumberOfRejectedMeasures (int numRejected)
 Set (update) the number of rejected measures for the control point.
 
int GetNumberOfRejectedMeasures () const
 Get the number of rejected measures on the control point.
 
double GetSampleResidualRms () const
 Get rms of sample residuals.
 
double GetLineResidualRms () const
 Get rms of line residuals.
 
double GetResidualRms () const
 Get rms of residuals.
 
void ClearJigsawRejected ()
 Set jigsaw rejected flag for all measures to false and set the jigsaw rejected flag for the point itself to false.
 
ControlPointFileEntryV0002 ToFileEntry () const
 

Static Public Member Functions

static QString PointTypeToString (PointType type)
 Obtain a string representation of a given PointType.
 
static PointType StringToPointType (QString pointTypeString)
 Obtain a PointType given a string representation of it.
 
static QString RadiusSourceToString (RadiusSource::Source source)
 Obtain a string representation of a given RadiusSource.
 
static RadiusSource::Source StringToRadiusSource (QString str)
 Obtain a RadiusSource::Source from a string.
 
static QString SurfacePointSourceToString (SurfacePointSource::Source source)
 Obtain a string representation of a given SurfacePointSource.
 
static SurfacePointSource::Source StringToSurfacePointSource (QString str)
 Obtain a SurfacePoint::Source from a string.
 

Static Public Attributes

static const int PointTypeCount = 3
 

Friends

class ControlNet
 

Detailed Description

A single control point.

A control point is one or more measurements that identify the same feature or location in different images.

Author
2005-07-29 Jeff Anderson
See Also
ControlMeasure ControlNet

Member Enumeration Documentation

This is a convenience member for checking number of constrained coordinates in the SurfacePoint.

Enumerator
LatitudeConstrained 

This is the status of constrained coordinates in the SurfacePoint.

LongitudeConstrained 
RadiusConstrained 

These are the valid 'types' of point.

A point type defines what a point is tying together.

Enumerator
Fixed 

A Fixed point is a Control Point whose lat/lon is well established and should not be changed.

Some people will refer to this as a truth (i.e., ground truth). A fixed point can be identifed in one or more cubes. Historically this point was called a "Ground" point.

Constrained 

A Constrained point is a Control Point whose lat/lon/radius is somewhat established and should not be changed.

Free 

A Free point is a Control Point that identifies common measurements between two or more cubes.

While it could have a lat/lon, it is not necessarily correct and is subject to change. This is the most common type of control point. This point type floats freely in a bundle adjustment. Historically this point type was called "Tie".

This is a return status for many of the mutating (setter) method calls.

We chose to use return status' because often times ignoring them is the behavior the caller wants.

Enumerator
Failure 

This is returned when an operation cannot be performed due to a problem such as the point is ignored and the operation doesn't make sense.

Success 

This is returned when the operation successfully took effect.

PointLocked 

This is returned when the operation requires Edit Lock to be false but it is currently true.

The operation did not take effect.

Constructor & Destructor Documentation

Isis::ControlPoint::ControlPoint ( )

Construct a control point.

Author
tsucharski (5/5/2010)

References Free, Isis::ControlPoint::SurfacePointSource::None, and Isis::ControlPoint::RadiusSource::None.

Isis::ControlPoint::ControlPoint ( const ControlPoint other)

Copy the given control point into this instance.

Parameters
otherThe control point to duplicate

References GetMeasure(), and SetRefMeasure().

Isis::ControlPoint::ControlPoint ( const QString &  newId)

Construct a control point with given Id.

Parameters
idControl Point Id

References Free, Isis::ControlPoint::SurfacePointSource::None, and Isis::ControlPoint::RadiusSource::None.

Isis::ControlPoint::ControlPoint ( const ControlPointFileEntryV0002 fileEntry,
const Distance majorRad,
const Distance minorRad,
const Distance polarRad 
)

This is used when reading from a protocol buffer.

Given a file representation (protocol buffer), and log data, construct the control point.

History:
2008-06-18 Debbie A. Cook, Swapped Init with SetRadii calls to avoid resetting the surface points with no radii

References _FILEINFO_, Isis::ControlPointFileEntryV0002::adjustedcovar(), Isis::ControlPointFileEntryV0002::adjustedcovar_size(), Isis::ControlPointFileEntryV0002::adjustedx(), Isis::ControlPointFileEntryV0002::adjustedy(), Isis::ControlPointFileEntryV0002::adjustedz(), Isis::ControlPointFileEntryV0002::aprioricovar(), Isis::ControlPointFileEntryV0002::aprioricovar_size(), Isis::ControlPointFileEntryV0002::aprioriradiussource(), Isis::ControlPointFileEntryV0002::aprioriradiussourcefile(), Isis::ControlPointFileEntryV0002::apriorisurfpointsource(), Isis::ControlPointFileEntryV0002::apriorisurfpointsourcefile(), Isis::ControlPointFileEntryV0002::apriorix(), Isis::ControlPointFileEntryV0002::aprioriy(), Isis::ControlPointFileEntryV0002::aprioriz(), Isis::ControlPoint::SurfacePointSource::AverageOfMeasures, Isis::ControlPoint::RadiusSource::AverageOfMeasures, Isis::ControlPoint::SurfacePointSource::Basemap, Isis::ControlPoint::SurfacePointSource::BundleSolution, Isis::ControlPoint::RadiusSource::BundleSolution, Isis::ControlPointFileEntryV0002::choosername(), Constrained, Isis::ControlPointFileEntryV0002_AprioriSource_AverageOfMeasures, Isis::ControlPointFileEntryV0002_AprioriSource_Basemap, Isis::ControlPointFileEntryV0002_AprioriSource_BundleSolution, Isis::ControlPointFileEntryV0002_AprioriSource_DEM, Isis::ControlPointFileEntryV0002_AprioriSource_Ellipsoid, Isis::ControlPointFileEntryV0002_AprioriSource_None, Isis::ControlPointFileEntryV0002_AprioriSource_Reference, Isis::ControlPointFileEntryV0002_AprioriSource_User, Isis::ControlPointFileEntryV0002_PointType_Constrained, Isis::ControlPointFileEntryV0002_PointType_Fixed, Isis::ControlPointFileEntryV0002_PointType_Free, Isis::ControlPointFileEntryV0002_PointType_obsolete_Ground, Isis::ControlPointFileEntryV0002_PointType_obsolete_Tie, Isis::ControlPointFileEntryV0002::datetime(), Isis::ControlPoint::RadiusSource::DEM, Isis::ControlPointFileEntryV0002::editlock(), Isis::ControlPoint::RadiusSource::Ellipsoid, Fixed, Free, Isis::ControlPointFileEntryV0002::has_adjustedx(), Isis::ControlPointFileEntryV0002::has_adjustedy(), Isis::ControlPointFileEntryV0002::has_adjustedz(), Isis::ControlPointFileEntryV0002::has_aprioriradiussource(), Isis::ControlPointFileEntryV0002::has_aprioriradiussourcefile(), Isis::ControlPointFileEntryV0002::has_apriorisurfpointsource(), Isis::ControlPointFileEntryV0002::has_apriorisurfpointsourcefile(), Isis::ControlPointFileEntryV0002::has_apriorix(), Isis::ControlPointFileEntryV0002::has_aprioriy(), Isis::ControlPointFileEntryV0002::has_aprioriz(), Isis::ControlPointFileEntryV0002::has_referenceindex(), Isis::ControlPointFileEntryV0002::id(), Isis::ControlPointFileEntryV0002::ignore(), Isis::Distance::isValid(), Isis::ControlPointFileEntryV0002::jigsawrejected(), LatitudeConstrained, Isis::ControlPointFileEntryV0002::latitudeconstrained(), LongitudeConstrained, Isis::ControlPointFileEntryV0002::longitudeconstrained(), Isis::ControlPointFileEntryV0002::measures(), Isis::ControlPointFileEntryV0002::measures_size(), Isis::Displacement::Meters, Isis::ControlPoint::SurfacePointSource::None, Isis::ControlPoint::RadiusSource::None, Isis::IException::Programmer, RadiusConstrained, Isis::ControlPointFileEntryV0002::radiusconstrained(), Isis::ControlPoint::SurfacePointSource::Reference, Isis::ControlPointFileEntryV0002::referenceindex(), Isis::SurfacePoint::SetRadii(), Isis::SurfacePoint::SetRectangularMatrix(), SetRefMeasure(), Isis::ControlPointFileEntryV0002::type(), Isis::ControlPoint::SurfacePointSource::User, and Isis::ControlPoint::RadiusSource::User.

Isis::ControlPoint::~ControlPoint ( )

This destroys the current instance and cleans up any and all allocated memory.

Member Function Documentation

void Isis::ControlPoint::Add ( ControlMeasure measure)

Add a measurement to the control point, taking ownership of the measure in the process.

Parameters
measureThe ControlMeasure to add

Referenced by Isis::QnetTool::createFixedPoint(), Isis::StereoTool::createPoint(), Isis::MatchTool::createPoint(), and Isis::QnetTool::createPoint().

void Isis::ControlPoint::ClearJigsawRejected ( )

Set jigsaw rejected flag for all measures to false and set the jigsaw rejected flag for the point itself to false.

References GetMeasure(), Isis::ControlMeasure::SetRejected(), and SetRejected().

Referenced by Isis::ControlNet::ClearJigsawRejected().

ControlPoint::Status Isis::ControlPoint::ComputeResiduals ( )

This method computes the BundleAdjust residuals for a point.

*** Warning:  Only BundleAdjust and its applications should be
              using this method.
History:

2008-07-17 Tracie Sucharski, Added ptid and measure serial number to the unable to map to surface error.

2009-12-06 Tracie Sucharski, Renamed from ComputeErrors

2010-08-05 Tracie Sucharski, Changed lat/lon/radius to x/y/z

2010-12-10 Debbie A. Cook, Revised error calculation for radar because it was always reporting line errors=0.

2011-03-17 Debbie A. Cook, Fixed typo in radar call to get longitude

2011-03-24 Debbie A. Cook, Removed IsMeasured check since it was really checking for Candidate measures.

2011-07-01 Debbie A. Cook, Removed editLock check to allow BundleAdjust to compute residuals for editLocked points

2012-01-18 Debbie A. Cook, Revised to call ComputeResidualsMillimeters() to avoid duplication of code

References _FILEINFO_, Isis::ControlMeasure::Camera(), ComputeResiduals_Millimeters(), Isis::CameraFocalPlaneMap::DetectorLine(), Isis::CameraFocalPlaneMap::DetectorSample(), Isis::Camera::DistortionMap(), Failure, Isis::Camera::FocalPlaneMap(), Isis::CameraDistortionMap::FocalPlaneX(), Isis::CameraDistortionMap::FocalPlaneY(), Isis::Camera::GetCameraType(), Isis::ControlMeasure::GetCubeSerialNumber(), Isis::ControlMeasure::GetFocalPlaneComputedX(), Isis::ControlMeasure::GetFocalPlaneComputedY(), Isis::ControlMeasure::GetFocalPlaneMeasuredX(), Isis::ControlMeasure::GetFocalPlaneMeasuredY(), GetId(), Isis::ControlMeasure::GetLine(), Isis::ControlMeasure::GetSample(), Isis::Sensor::GetSurfacePoint(), Isis::CameraGroundMap::GetXY(), Isis::Camera::GroundMap(), Isis::ControlMeasure::IsIgnored(), IsIgnored(), Isis::IException::Programmer, Isis::Camera::Radar, Isis::CameraFocalPlaneMap::SetFocalPlane(), Isis::Camera::SetImage(), Isis::ControlMeasure::SetResidual(), Isis::CameraDistortionMap::SetUndistortedFocalPlane(), and Success.

ControlPoint::Status Isis::ControlPoint::ComputeResiduals_Millimeters ( )

This method computes the residuals for a point.

History:

2008-07-17 Tracie Sucharski - Added ptid and measure serial number to the unable to map to surface error.

2010-12-06 Tracie Sucharski - Renamed from ComputeErrors

2011-03-19 Debbie A. Cook - Changed to use the Camera classes like ComputeResiduals and get the correct calculations for each camera type.

2011-03-24 Debbie A. Cook - Removed IsMeasured check since it was really checking for Candidate measures.

2012-01-18 Debbie A. Cook - Made radar case the same as other instruments and removed incorrect call to SetResidual, which was setting focal plane residuals in x and y instead of image residuals in sample and line.

References Isis::ControlMeasure::Camera(), Failure, GetAdjustedSurfacePoint(), Isis::Camera::GetCameraType(), Isis::ControlMeasure::GetLine(), Isis::ControlMeasure::GetSample(), Isis::CameraGroundMap::GetXY(), Isis::Camera::GroundMap(), Isis::ControlMeasure::IsIgnored(), IsIgnored(), Isis::ControlMeasure::SetFocalPlaneComputed(), Isis::Camera::SetImage(), and Success.

Referenced by ComputeResiduals().

int Isis::ControlPoint::Delete ( ControlMeasure measure)

Remove a measurement from the control point, deleting reference measure is allowed.

Parameters
measureThe measure to delete

References ASSERT, and Isis::ControlMeasure::GetCubeSerialNumber().

Referenced by Delete(), Isis::ControlNet::DeleteMeasuresWithId(), Isis::MatchTool::deletePoint(), Isis::CnetViz::AbstractMeasureItem::deleteSource(), Isis::CnetEditorWidget::filteredNetwork(), and operator=().

int Isis::ControlPoint::Delete ( QString  serialNumber)

Remove a measurement from the control point, deleting reference measure is allowed.

Parameters
serialNumberThe serial number of the measure to delete

References Isis::ControlMeasure::IsEditLocked(), Isis::ControlMeasure::IsIgnored(), IsIgnored(), Isis::ControlMeasure::MeasureLocked, and Isis::ControlMeasure::Success.

int Isis::ControlPoint::Delete ( int  index)

Remove a measurement from the control point, deleting reference measure is allowed.

Parameters
indexThe index of the control measure to delete

References _FILEINFO_, Delete(), and Isis::IException::Programmer.

ControlPoint::RadiusSource::Source Isis::ControlPoint::GetAprioriRadiusSource ( ) const

Referenced by ToFileEntry().

QString Isis::ControlPoint::GetAprioriRadiusSourceFile ( ) const
ControlPoint::SurfacePointSource::Source Isis::ControlPoint::GetAprioriSurfacePointSource ( ) const
QString Isis::ControlPoint::GetAprioriSurfacePointSourceFile ( ) const
SurfacePoint Isis::ControlPoint::GetBestSurfacePoint ( ) const

Returns the adjusted surface point if it exists, otherwise returns the a priori surface point.

References Isis::SurfacePoint::Valid().

Referenced by Isis::QnetPointRangeFilter::filter(), and Isis::QnetPointDistanceFilter::filter().

QList< QString > Isis::ControlPoint::getCubeSerialNumbers ( ) const
Returns
A list of cube serial numbers

Referenced by Isis::ControlNet::SetImages().

QString Isis::ControlPoint::GetDateTime ( ) const
double Isis::ControlPoint::GetLineResidualRms ( ) const
ControlMeasure * Isis::ControlPoint::GetMeasure ( QString  serialNumber)

Get a control measure based on its cube's serial number.

Parameters
serialNumberserial number of measure to get
Returns
control measure with matching serial number
const ControlMeasure * Isis::ControlPoint::GetMeasure ( int  index) const
ControlMeasure * Isis::ControlPoint::GetMeasure ( int  index)
QList< ControlMeasure * > Isis::ControlPoint::getMeasures ( bool  excludeIgnored = false) const
Parameters
excludeIgnoredIgnored measures are excluded if this is true. It is false by default.
Returns
A list of this points measures

References Isis::ControlMeasure::IsIgnored().

Referenced by Isis::ControlNet::AddPoint(), Isis::ControlNet::DeletePoint(), Isis::CnetViz::MeasureCountFilter::evaluate(), Isis::CnetViz::AbstractFilter::evaluatePointFromMeasureFilter(), and Isis::ControlPointGraphicsItem::paint().

int Isis::ControlPoint::GetNumberOfRejectedMeasures ( ) const

Get the number of rejected measures on the control point.

Returns
The number of rejected measures on this control point
QString Isis::ControlPoint::GetPointTypeString ( ) const

Obtain a string representation of the PointType.

Returns
A string representation of the PointType

References GetType(), and PointTypeToString().

Referenced by Isis::CnetViz::PointTypeFilter::evaluate(), and Isis::CnetViz::AbstractPointItem::getData().

QString Isis::ControlPoint::GetRadiusSourceString ( ) const

Obtain a string representation of the RadiusSource.

Returns
A string representation of the RadiusSource

References RadiusSourceToString().

Referenced by Isis::CnetViz::AbstractPointItem::getData().

QString Isis::ControlPoint::GetReferenceSN ( ) const
Returns
The cube serial number of the reference measure

References _FILEINFO_, Isis::ControlMeasure::GetCubeSerialNumber(), GetId(), and Isis::IException::Programmer.

ControlMeasure * Isis::ControlPoint::GetRefMeasure ( )

Get the measure that is the reference directly.

References _FILEINFO_, GetId(), and Isis::IException::Programmer.

double Isis::ControlPoint::GetSampleResidualRms ( ) const
Statistics Isis::ControlPoint::GetStatistic ( double(ControlMeasure::*)() const  statFunc) const

This function will call a given method on every control measure that this point has.

Parameters
statFuncThe function to use for data collection
Returns
The gathered statistic
History:
2011-03-08 Debbie A. Cook - Changed to get statistics for all point types and not just Candidate.

References Isis::Statistics::AddData(), and Isis::ControlMeasure::IsIgnored().

Referenced by Isis::ControlNet::AverageResidual(), Isis::QnetPointJigsawErrorFilter::filter(), Isis::QnetPointRegistrationErrorFilter::filter(), and Isis::ControlNet::GetMaximumResidual().

QString Isis::ControlPoint::GetSurfacePointSourceString ( ) const

Obtain a string representation of the SurfacePointSource.

Returns
A string representation of the SurfacePointSource

References SurfacePointSourceToString().

Referenced by Isis::CnetViz::AbstractPointItem::getData().

bool Isis::ControlPoint::HasAprioriCoordinates ( )
bool Isis::ControlPoint::HasSerialNumber ( QString  serialNumber) const

Return true if given serial number exists in point.

Parameters
serialNumberThe serial number
Returns
True if point contains serial number, false if not

Referenced by Isis::StereoTool::paintViewport(), Isis::CnetViz::AbstractPointItem::setData(), and Isis::QnetNewMeasureDialog::setFiles().

int Isis::ControlPoint::IndexOf ( ControlMeasure cm,
bool  throws = true 
) const
Parameters
cmThe control measure to find the index of
throwsThrows an exception on failure instead of returning -1. Be aware that by default this is true!
Returns
The index of the passed in measure, or -1 on failure if throws is false.

References ASSERT, and Isis::ControlMeasure::GetCubeSerialNumber().

int Isis::ControlPoint::IndexOf ( QString  sn,
bool  throws = true 
) const
Parameters
snThe serial number of the control measure to find the index of
throwsThrows an exception on failure instead of returning -1. Be aware that by default this is true!
Returns
The index of the measure with serial number matching sn, or -1 on failure if throws is false.

References _FILEINFO_, and Isis::IException::Programmer.

int Isis::ControlPoint::IndexOfRefMeasure ( ) const
Parameters
throwsThrows an exception on failure instead of returning -1. Be aware that by default this is true!
Returns
The index of the reference measure, or -1 if no measures exist in the point (A point with at least one measure ALWAYS has a reference measure.

References _FILEINFO_, ASSERT, Isis::ControlMeasure::GetCubeSerialNumber(), and Isis::IException::Programmer.

Referenced by Isis::InterestOperator::FindCnetRef(), and ToFileEntry().

bool Isis::ControlPoint::IsConstrained ( )
bool Isis::ControlPoint::IsFixed ( ) const

References Fixed.

bool Isis::ControlPoint::IsInvalid ( ) const
bool Isis::ControlPoint::IsLatitudeConstrained ( )

References LatitudeConstrained.

Referenced by ComputeApriori().

bool Isis::ControlPoint::IsLongitudeConstrained ( )

References LongitudeConstrained.

Referenced by ComputeApriori().

bool Isis::ControlPoint::IsRadiusConstrained ( )

References RadiusConstrained.

Referenced by ComputeApriori().

bool Isis::ControlPoint::IsReferenceExplicit ( ) const
Returns
true Returns true if SetRefMeasure has ever been set on this point.

Referenced by Isis::MatchTool::deletePoint().

bool Isis::ControlPoint::IsValid ( ) const
void Isis::ControlPoint::Load ( PvlObject p)

Loads the PvlObject into a ControlPoint.

Parameters
pPvlObject containing ControlPoint information
forceBuildAllows invalid Control Measures to be added to this Control Point
Exceptions
Isis::iException::User- Invalid Point Type
Isis::iException::User- Unable to add ControlMeasure to Control Point
History:

2008-06-18 Tracie Sucharski/Jeannie Walldren, Fixed bug with checking for "True" vs "true", change to lower case for comparison.

2009-12-29 Tracie Sucharski - Added new ControlPoint information.

2010-01-13 Tracie Sucharski - Changed from Set methods to simply setting private variables to increase speed?

2010-07-30 Tracie Sucharski, Updated for changes made after additional working sessions for Control network design.

2010-09-01 Tracie Sucharski, Add checks for AprioriLatLonSource AprioriLatLonSourceFile. If there are AprioriSigmas,but no AprioriXYZ, use the XYZ values.

2010-09-15 Tracie Sucharski, It was decided after mtg with Debbie, Stuart, Ken and Tracie that ControlPoint will only function with x/y/z, not lat/lon/radius. It will be the responsibility of the application or class using ControlPoint to set up a SurfacePoint object to do conversions between x/y/z and lat/lon/radius. So... remove all conversion methods from this class. It was also decided that when importing old networks that contain Sigmas, the sigmas will not be imported , due to conflicts with the units of the sigmas,we cannot get accurate x,y,z sigams from the lat,lon,radius sigmas without the covariance matrix.

2010-09-28 Tracie Sucharski, Added back the conversion methods from lat,lon,radius to x,y,z only for the point, since that is what most applications need.

2010-12-02 Debbie A. Cook, Added units to SurfacePoint.SetSpherical calls.

2011-03-12 Debbie A. Cook, Added targetRadius to do conversions

int Isis::ControlPoint::NumberOfConstrainedCoordinates ( )

Referenced by ComputeApriori().

bool Isis::ControlPoint::operator!= ( const ControlPoint other) const

Compare two Control Points for inequality.

Parameters
otherThe other point to compare this one to
Returns
true if the two points are not equal, and false otherwise
const ControlPoint & Isis::ControlPoint::operator= ( const ControlPoint other)
Parameters
pPoint
Returns
ControlPoint&

References Delete(), and SetRefMeasure().

bool Isis::ControlPoint::operator== ( const ControlPoint other) const

Compare two Control Points for equality.

Parameters
otherThe other point to compare to
Returns
true if the two points are equal, and false otherwise

References GetNumMeasures().

const ControlMeasure * Isis::ControlPoint::operator[] ( QString  serialNumber) const

Same as GetMeasure (provided for convenience)

Parameters
serialNumberCube serial number of desired control measure
Returns
const version of the measure which has the provided serial number

References GetMeasure().

ControlMeasure * Isis::ControlPoint::operator[] ( QString  serialNumber)

Same as GetMeasure (provided for convenience)

Parameters
serialNumberCube serial number of desired control measure
Returns
The measure which has the provided serial number

References GetMeasure().

const ControlMeasure * Isis::ControlPoint::operator[] ( int  index) const

Same as GetMeasure (provided for convenience)

Parameters
indexIf there are n measures, the measure returned will be the ith measure added to the point
Returns
const version of the measure which has the provided serial number

References GetMeasure().

ControlMeasure * Isis::ControlPoint::operator[] ( int  index)

Same as GetMeasure (provided for convenience)

Parameters
indexIf there are n measures, the measure returned will be the ith measure added to the point
Returns
The measure which has the provided serial number

References GetMeasure().

QString Isis::ControlPoint::PointTypeToString ( PointType  pointType)
static

Obtain a string representation of a given PointType.

Parameters
typePointType to convert to a string
Returns
A string representation of type

References Constrained, Fixed, and Free.

Referenced by GetPointTypeString(), and Isis::CnetViz::PointTableDelegate::getWidget().

QString Isis::ControlPoint::RadiusSourceToString ( RadiusSource::Source  source)
static
ControlPoint::Status Isis::ControlPoint::ResetApriori ( )

Reset all the Apriori info to defaults.

Author
Sharmila Prasad (10/22/2010)

References IsEditLocked(), Isis::ControlPoint::SurfacePointSource::None, Isis::ControlPoint::RadiusSource::None, PointLocked, and Success.

ControlPoint::Status Isis::ControlPoint::SetAdjustedSurfacePoint ( SurfacePoint  newSurfacePoint)

Set or update the surface point relating to this control point.

This is the point on the surface of the planet that the measures are tied to. This updates the last modified attributes of this point. *** Warning: Only BundleAdjust and its applications should be using this method.

Parameters
newSurfacePointThe point on the target's surface the measures are tied to

References Success.

Referenced by Isis::CnetViz::AbstractPointItem::setData().

ControlPoint::Status Isis::ControlPoint::SetAprioriRadiusSource ( RadiusSource::Source  source)

This updates the source of the radius of the apriori surface point.

See Also
RadiusSource::Source
Parameters
sourceWhere the radius came from

References PointLocked, and Success.

Referenced by ComputeApriori(), and Isis::CnetViz::AbstractPointItem::setData().

ControlPoint::Status Isis::ControlPoint::SetAprioriRadiusSourceFile ( QString  sourceFile)

This updates the filename of the DEM that the apriori radius came from.

It doesn't really make sense to call this unless the RadiusSource is DEM.

See Also
RadiusSource::Source
Parameters
sourceWhere the radius came from

References PointLocked, and Success.

Referenced by Isis::CnetViz::AbstractPointItem::setData().

ControlPoint::Status Isis::ControlPoint::SetAprioriSurfacePointSource ( SurfacePointSource::Source  source)

This updates the source of the surface point.

See Also
SurfacePointSource::Source
Parameters
sourceWhere the surface point came from

References PointLocked, and Success.

Referenced by ComputeApriori(), and Isis::CnetViz::AbstractPointItem::setData().

ControlPoint::Status Isis::ControlPoint::SetAprioriSurfacePointSourceFile ( QString  sourceFile)

This updates the filename of where the apriori surface point came from.

See Also
RadiusSource::Source
Parameters
sourceFileWhere the surface point came from

References PointLocked, and Success.

Referenced by Isis::CnetViz::AbstractPointItem::setData().

ControlPoint::Status Isis::ControlPoint::SetChooserName ( QString  name)

Set the point's chooser name.

This will be lost if any attributes relating to this point is later changed and the current user will be set. This is one of the 'last modified attributes' referred to in other comments.

Parameters
nameThe username of the person who last modified this control point

References PointLocked, and Success.

Referenced by Isis::QnetTool::createFixedPoint(), Isis::MatchTool::createPoint(), Isis::QnetTool::createPoint(), and Isis::CnetViz::AbstractPointItem::setData().

ControlPoint::Status Isis::ControlPoint::SetDateTime ( QString  newDateTime)

Set the point's last modified time.

This will be lost if any attributes relating to this point are later changed and the current time will be set. This is one of the 'last modified attributes' referred to in other comments.

Parameters
newDateTimeThe date and time this control point was last modified

References PointLocked, and Success.

Referenced by Isis::CnetViz::AbstractPointItem::setData().

ControlPoint::Status Isis::ControlPoint::SetEditLock ( bool  lock)

Set the EditLock state.

If edit lock is on, then most attributes relating to this point are not modifiable. Edit lock is like "Don't modify my attributes, but you can still modify my measures' attributes". The reference measure is implicitely edit locked if the point is edit locked.

Parameters
lockTrue to enable edit lock, false to disable it and allow the point to be modified.

References Success.

Referenced by Isis::CnetEditorWidget::filteredNetwork(), Isis::CnetViz::AbstractPointItem::setData(), and Isis::MatchTool::updatePointInfo().

ControlPoint::Status Isis::ControlPoint::SetId ( QString  newId)

Sets the Id of the control point.

Parameters
idControl Point Id
Returns
(int) status Success or PointLocked

References PointLocked, and Success.

Referenced by Isis::CnetViz::AbstractPointItem::setData().

ControlPoint::Status Isis::ControlPoint::SetIgnored ( bool  newIgnoreStatus)

Set whether to ignore or use control point.

Parameters
newIgnoreStatusTrue to ignore this Control Point, False to un-ignore

References Isis::ControlMeasure::IsIgnored(), PointLocked, and Success.

Referenced by Isis::InterestOperator::FindCnetRef(), Isis::InterestOperator::ProcessLocked_Point_Reference(), Isis::CnetViz::AbstractPointItem::setData(), and Isis::MatchTool::updatePointInfo().

void Isis::ControlPoint::SetNumberOfRejectedMeasures ( int  numRejected)

Set (update) the number of rejected measures for the control point.

Parameters
numRejectedThe number of rejected measures
ControlPoint::Status Isis::ControlPoint::SetRefMeasure ( ControlMeasure cm)

Set the point's reference measure.

Parameters
cmThe new reference measure

References ASSERT, PointLocked, and Success.

Referenced by ControlPoint(), Isis::InterestOperator::FindCnetRef(), operator=(), and Isis::CnetViz::AbstractPointItem::setData().

ControlPoint::Status Isis::ControlPoint::SetRefMeasure ( int  index)

Set the point's reference measure.

Parameters
indexThe index of the new reference measure

References _FILEINFO_, PointLocked, Isis::IException::Programmer, Success, and Isis::toString().

ControlPoint::Status Isis::ControlPoint::SetRefMeasure ( QString  sn)

Set the points reference measure.

Parameters
snThe serial number of the new reference measure

References _FILEINFO_, PointLocked, Isis::IException::Programmer, and Success.

ControlPoint::Status Isis::ControlPoint::SetRejected ( bool  reject)

Set the jigsawRejected state.

If IsRejected is true, then this point should be ignored until the next iteration in the bundle adjustement. BundleAdjust decides when to reject or accept a point. The initial IsRejected state of a measure is false.

Parameters
rejectTrue to reject a measure, false to include it in the adjustment

References Success.

Referenced by ClearJigsawRejected().

ControlPoint::Status Isis::ControlPoint::SetType ( PointType  newType)

Updates the control point's type.

This updates the last modified attributes of this point.

See Also
PointType
Parameters
newTypeThe new type this control point should be

References _FILEINFO_, Constrained, Fixed, Free, GetId(), PointLocked, Isis::IException::Programmer, and Success.

Referenced by Isis::QnetTool::createFixedPoint(), Isis::StereoTool::createPoint(), Isis::MatchTool::createPoint(), and Isis::CnetViz::AbstractPointItem::setData().

ControlPoint::PointType Isis::ControlPoint::StringToPointType ( QString  pointTypeString)
static

Obtain a PointType given a string representation of it.

Parameters
pointTypeStringfor the requested PointType
Returns
the PointType for the given string

References _FILEINFO_, Constrained, Fixed, Free, and Isis::IException::Programmer.

Referenced by Isis::CnetViz::AbstractPointItem::setData().

ControlPoint::SurfacePointSource::Source Isis::ControlPoint::StringToSurfacePointSource ( QString  str)
static
ControlPointFileEntryV0002 Isis::ControlPoint::ToFileEntry ( ) const

References Isis::ControlPointFileEntryV0002::add_adjustedcovar(), Isis::ControlPointFileEntryV0002::add_aprioricovar(), Isis::ControlPointFileEntryV0002::add_measures(), Isis::ControlPoint::SurfacePointSource::AverageOfMeasures, Isis::ControlPoint::RadiusSource::AverageOfMeasures, Isis::ControlPoint::SurfacePointSource::Basemap, Isis::ControlPoint::SurfacePointSource::BundleSolution, Isis::ControlPoint::RadiusSource::BundleSolution, Constrained, Isis::ControlPointFileEntryV0002::Constrained, Isis::ControlPointFileEntryV0002_AprioriSource_AverageOfMeasures, Isis::ControlPointFileEntryV0002_AprioriSource_Basemap, Isis::ControlPointFileEntryV0002_AprioriSource_BundleSolution, Isis::ControlPointFileEntryV0002_AprioriSource_DEM, Isis::ControlPointFileEntryV0002_AprioriSource_Ellipsoid, Isis::ControlPointFileEntryV0002_AprioriSource_Reference, Isis::ControlPointFileEntryV0002_AprioriSource_User, Isis::ControlPoint::RadiusSource::DEM, Isis::ControlPoint::RadiusSource::Ellipsoid, Fixed, Isis::ControlPointFileEntryV0002::Fixed, Free, Isis::ControlPointFileEntryV0002::Free, GetAdjustedSurfacePoint(), GetAprioriRadiusSource(), GetAprioriRadiusSourceFile(), GetAprioriSurfacePoint(), GetAprioriSurfacePointSource(), GetAprioriSurfacePointSourceFile(), GetChooserName(), GetDateTime(), GetId(), Isis::SurfacePoint::GetRectangularMatrix(), GetType(), Isis::SurfacePoint::GetX(), Isis::SurfacePoint::GetY(), Isis::SurfacePoint::GetZ(), IndexOfRefMeasure(), IsEditLocked(), IsIgnored(), IsRejected(), LatitudeConstrained, LongitudeConstrained, Isis::Displacement::meters(), Isis::ControlPoint::SurfacePointSource::None, Isis::ControlPoint::RadiusSource::None, RadiusConstrained, Isis::ControlPoint::SurfacePointSource::Reference, Isis::ControlPointFileEntryV0002::set_adjustedx(), Isis::ControlPointFileEntryV0002::set_adjustedy(), Isis::ControlPointFileEntryV0002::set_adjustedz(), Isis::ControlPointFileEntryV0002::set_aprioriradiussource(), Isis::ControlPointFileEntryV0002::set_aprioriradiussourcefile(), Isis::ControlPointFileEntryV0002::set_apriorisurfpointsource(), Isis::ControlPointFileEntryV0002::set_apriorisurfpointsourcefile(), Isis::ControlPointFileEntryV0002::set_apriorix(), Isis::ControlPointFileEntryV0002::set_aprioriy(), Isis::ControlPointFileEntryV0002::set_aprioriz(), Isis::ControlPointFileEntryV0002::set_choosername(), Isis::ControlPointFileEntryV0002::set_datetime(), Isis::ControlPointFileEntryV0002::set_editlock(), Isis::ControlPointFileEntryV0002::set_id(), Isis::ControlPointFileEntryV0002::set_ignore(), Isis::ControlPointFileEntryV0002::set_jigsawrejected(), Isis::ControlPointFileEntryV0002::set_latitudeconstrained(), Isis::ControlPointFileEntryV0002::set_longitudeconstrained(), Isis::ControlPointFileEntryV0002::set_radiusconstrained(), Isis::ControlPointFileEntryV0002::set_referenceindex(), Isis::ControlPointFileEntryV0002::set_type(), Isis::ControlPoint::SurfacePointSource::User, and Isis::ControlPoint::RadiusSource::User.

Referenced by Isis::ControlNet::Write().

void Isis::ControlPoint::ZeroNumberOfRejectedMeasures ( )

Initialize the number of rejected measures to 0.

Friends And Related Function Documentation

friend class ControlNet
friend

Member Data Documentation

const int Isis::ControlPoint::PointTypeCount = 3
static

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