USGS

Isis 3.0 Object Programmers' Reference

Home

Isis::CameraPointInfo Class Reference

#include <CameraPointInfo.h>

Collaboration diagram for Isis::CameraPointInfo:

Collaboration graph
[legend]
List of all members.

Detailed Description

CameraPointInfo provides quick access to the majority of information avaliable from a camera on a point.

CameraPointInfo provides the functionality which was a part of campt in class form. This functionality is access to the majoirty of information avaliable on any given point on an image. The main difference is the use of a CubeManager within CameraPointInfo for effeciency when working with control nets and the opening of cubes several times.

Author:
2009-08-25 Mackenzie Boyd

For internal use only.

History:
2009-09-13 Mackenzie Boyd - Added methods SetCenter, SetSample and SetLine to support campt functionality. Added CheckCube private method to check currentCube isn't NULL.

Definition at line 55 of file CameraPointInfo.h.

Public Member Functions

 CameraPointInfo ()
 Constructor, initializes CubeManager and other variables for use.
virtual ~CameraPointInfo ()
 Destructor, deletes CubeManager object used.
void SetCube (const std::string &cubeFilename)
 SetCube opens the given cube in a CubeManager.
PvlGroupSetImage (const double sample, const double line)
 SetImage sets a sample, line image coordinate in the camera so data can be accessed.
PvlGroupSetCenter ()
 SetCenter sets the image coordinates to the center of the image.
PvlGroupSetSample (double sample)
 SetSample sets the image coordinates to the center line and the given sample.
PvlGroupSetLine (double line)
 SetLine sets the image coordinates to the center sample and the given line.
PvlGroupSetGround (const double latitude, const double longitude)
 SetGround sets a latitude, longitude grrund coordinate in the camera so data can be accessed.
void AllowOutside (const bool outsideAccepted)
 Sets boolean value if outside cube locations are acceptable.
bool AllowOutside ()
 Returns whether or not locations outside the cube are acceptable.

Private Member Functions

bool CheckCube ()
 CheckCube checks that a cube has been set before the data for a point is accessed.
void CheckConditions ()
 Checks two possible failure conditions involving no surface intersection and not being inside the cube.
PvlGroupGetPointInfo ()
 GetPointInfo builds the PvlGroup containing all the important information derived from the Camera.

Private Attributes

CubeManagerusedCubes
bool outsideAccepted
CubecurrentCube
Cameracamera


Constructor & Destructor Documentation

Isis::CameraPointInfo::CameraPointInfo (  ) 

Constructor, initializes CubeManager and other variables for use.

Definition at line 41 of file CameraPointInfo.cpp.

References camera, currentCube, outsideAccepted, Isis::CubeManager::SetNumOpenCubes(), and usedCubes.

Isis::CameraPointInfo::~CameraPointInfo (  )  [virtual]

Destructor, deletes CubeManager object used.

Definition at line 53 of file CameraPointInfo.cpp.

References usedCubes.


Member Function Documentation

bool Isis::CameraPointInfo::AllowOutside (  ) 

Returns whether or not locations outside the cube are acceptable.

Returns:
bool Outside cube locations acceptable.

Definition at line 341 of file CameraPointInfo.cpp.

References outsideAccepted.

void Isis::CameraPointInfo::AllowOutside ( const bool  outsideAccepted  ) 

Sets boolean value if outside cube locations are acceptable.

Parameters:
outside Boolean setting if locations outside are acceptable.

Definition at line 330 of file CameraPointInfo.cpp.

References outsideAccepted.

void Isis::CameraPointInfo::CheckConditions (  )  [private]

Checks two possible failure conditions involving no surface intersection and not being inside the cube.

Definition at line 312 of file CameraPointInfo.cpp.

References _FILEINFO_, camera, Isis::Sensor::HasSurfaceIntersection(), Isis::Camera::InCube(), Isis::iException::Message(), and outsideAccepted.

Referenced by GetPointInfo().

bool Isis::CameraPointInfo::CheckCube (  )  [private]

CheckCube checks that a cube has been set before the data for a point is accessed.

Returns:
bool Whether or not a cube has been set, true if it has been.

Definition at line 179 of file CameraPointInfo.cpp.

References _FILEINFO_, currentCube, and Isis::iException::Message().

Referenced by SetCenter(), SetGround(), SetImage(), SetLine(), and SetSample().

PvlGroup * Isis::CameraPointInfo::GetPointInfo (  )  [private]

GetPointInfo builds the PvlGroup containing all the important information derived from the Camera.

Returns:
PvlGroup* Data taken directly from the Camera and drived from Camera information. Ownership passed.

Definition at line 197 of file CameraPointInfo.cpp.

References Isis::PvlKeyword::AddComment(), Isis::PvlContainer::AddKeyword(), Isis::PvlKeyword::AddValue(), b, camera, CheckConditions(), Isis::Sensor::Coordinate(), currentCube, Isis::Sensor::Declination(), Isis::Sensor::EmissionAngle(), Isis::Spice::EphemerisTime(), Isis::Cube::Filename(), Isis::Camera::GroundAzimuth(), Isis::Sensor::IncidenceAngle(), Isis::Spice::InstrumentPosition(), Isis::Camera::Line(), Isis::Camera::LineResolution(), Isis::Sensor::LocalRadius(), Isis::Sensor::LocalSolarTime(), Isis::Camera::NorthAzimuth(), Isis::Camera::OffNadirAngle(), phase, Isis::Sensor::PhaseAngle(), Isis::PixelToString(), Isis::Cube::PixelType(), Isis::Spice::Radii(), Isis::Cube::Read(), Isis::Sensor::RightAscension(), Isis::Camera::Sample(), Isis::Camera::SampleResolution(), Isis::Sensor::SlantDistance(), Isis::Sensor::SolarDistance(), Isis::Spice::SolarLongitude(), Isis::Sensor::SpacecraftAltitude(), Isis::Camera::SpacecraftAzimuth(), Isis::Spice::SubSolarPoint(), Isis::Spice::SubSpacecraftPoint(), Isis::Camera::SunAzimuth(), Isis::Spice::SunPosition(), Isis::Spice::TargetCenterDistance(), Isis::Projection::ToPlanetographic(), Isis::Sensor::UniversalLatitude(), and Isis::Sensor::UniversalLongitude().

Referenced by SetCenter(), SetGround(), SetImage(), SetLine(), and SetSample().

PvlGroup * Isis::CameraPointInfo::SetCenter (  ) 

SetCenter sets the image coordinates to the center of the image.

Returns:
PvlGroup* The pertinent data from the Camera class on the point. Ownership is passed to caller.

Definition at line 99 of file CameraPointInfo.cpp.

References camera, CheckCube(), currentCube, GetPointInfo(), Isis::Cube::Lines(), Isis::Cube::Samples(), and Isis::Camera::SetImage().

void Isis::CameraPointInfo::SetCube ( const std::string &  cubeFilename  ) 

SetCube opens the given cube in a CubeManager.

The CubeManager is for effeciency when working with control nets where cubes are accesed multiple times.

Parameters:
cubeFilename A cube filename

Definition at line 66 of file CameraPointInfo.cpp.

References Isis::Cube::Camera(), camera, currentCube, Isis::CubeManager::OpenCube(), and usedCubes.

PvlGroup * Isis::CameraPointInfo::SetGround ( const double  latitude,
const double  longitude 
)

SetGround sets a latitude, longitude grrund coordinate in the camera so data can be accessed.

Parameters:
latitude A latitude coordinate in or almost in the cube
longitude A longitude coordinate in or almost in the cube
Returns:
PvlGroup* The pertinent data from the Camera class on the point. Ownership is passed to caller.

Definition at line 161 of file CameraPointInfo.cpp.

References camera, CheckCube(), GetPointInfo(), and Isis::Camera::SetUniversalGround().

PvlGroup * Isis::CameraPointInfo::SetImage ( const double  sample,
const double  line 
)

SetImage sets a sample, line image coordinate in the camera so data can be accessed.

Parameters:
sample A sample coordinate in or almost in the cube
line A line coordinate in or almost in the cubei
Returns:
PvlGroup* The pertinent data from the Camera class on the point. Ownership is passed to caller.

Definition at line 82 of file CameraPointInfo.cpp.

References camera, CheckCube(), GetPointInfo(), and Isis::Camera::SetImage().

PvlGroup * Isis::CameraPointInfo::SetLine ( double  line  ) 

SetLine sets the image coordinates to the center sample and the given line.

Returns:
PvlGroup* The pertinent data from the Camera class on the point. Ownership is passed to caller.

Definition at line 137 of file CameraPointInfo.cpp.

References camera, CheckCube(), currentCube, GetPointInfo(), Isis::Cube::Samples(), and Isis::Camera::SetImage().

PvlGroup * Isis::CameraPointInfo::SetSample ( double  sample  ) 

SetSample sets the image coordinates to the center line and the given sample.

Returns:
PvlGroup* The pertinent data from the Camera class on the point. Ownership is passed to caller.

Definition at line 118 of file CameraPointInfo.cpp.

References camera, CheckCube(), currentCube, GetPointInfo(), Isis::Cube::Lines(), and Isis::Camera::SetImage().


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