VR-Forces 4.1.1 Class Documentation
List of all members | Public Member Functions | Static Public Member Functions | Protected Member Functions | Static Protected Member Functions | Protected Attributes | Private Member Functions
makVrv::DtUtmCoordinateConverter Class Reference

Instances of DtUtmCoordSystem provide transformations and utilities for converting between network and UTM database coordinates. More...

Inheritance diagram for makVrv::DtUtmCoordinateConverter:
Inheritance graph
[legend]

Public Member Functions

 DtUtmCoordinateConverter ()
 default constructor
virtual ~DtUtmCoordinateConverter ()
 destructor
virtual DtCoordinateConverterclone () const
 Clone the coordinate converter;.
virtual void init (double lat, double lon, long zone=0, int useStandardOffsets=0)
 Initialize converter with the origin's latitude and longitude, and an optional zone and standard offsets.
virtual void init (double lat, double lon, double z, long zone=0, int useStandardOffsets=0)
 Initialize converter with the origin's latitude and longitude and a z value, and an optional zone and standard offsets.
virtual void init (const DtGeodeticCoord &origin, long zone=0, int useStandardOffsets=0)
 Initialize converter with the origin's and an optional zone and standard offsets.
virtual void init (DtDegMinSec lat, DtDegMinSec lon, long zone=0, int useStandardOffsets=0)
 Initialize converter with the origin's latitude and longitude, and an optional zone and standard offsets.
virtual void init (DtDegMinSec lat, DtDegMinSec lon, double z, long zone=0, int useStandardOffsets=0)
 Initialize converter with the origin's latitude and longitude and a z-value, and an optional zone and standard offsets.
virtual void init (long zone, char hemisphere= 'N', bool useMpiDefaultOrigin=true)
 Initialize converter with the zone.
virtual void init (double falseOriginX, double falseOriginY, double falseOriginZ, long zone, char hemisphere= 'N', bool useMpiDefaultOrigin=true)
 Initialize converter with a false origin and zone.
virtual bool init (const std::string &originstring)
 Initialize converter with an origin string.
virtual std::string stringRep ()
 Convert to string.
virtual const DtGeodeticCoord & origin () const
 Get the origin origin is (latitude, longitude, alt) in degrees and meters (alt = 0 always)
virtual bool useStandardOffsets () const
 Get standard offsets.
virtual long zone () const
 Set/Get the zone.
virtual void setZone (long zone)
virtual DtDegMinSec latRef () const
 Get the reference latitude and longitude.
virtual DtDegMinSec longRef () const
virtual void geocToCig (const DtVector &geoc, DtVector &out) const
 geoc coordinates to cig coordinates
virtual const DtUtmReferencePoint * referencePoint () const
virtual void cigToGeoc (const DtVector &in, DtVector &geoc) const
 cig coordinates to geoc coordinates
virtual void setupTopoFrame (const DtVector &truth)
 Update all our transformation matrices based on the current database position.
- Public Member Functions inherited from makVrv::DtCoordinateConverter
virtual ~DtCoordinateConverter ()
 destructor
virtual const std::string & type () const
 Get converter type - this base class type is NoOp.
virtual bool zIsAlt () const
 get whether 3rd element corresponds to altitude in this coordinate system
virtual bool usesOffsetFile () const
 get whether Warbreaker type file needed
virtual DtGeodeticCoord databaseOrigin () const
 get database origin (cig) Origin is (latitude, longitude, alt) in degrees and meters (alt = 0 always)
virtual void setGeocOriginOffset (const DtVector &offset)
 set origin offset (geoc cig origin)
virtual void reset ()
 Reset the coordinate converter This function recalculates constants used for conversions.
virtual const DtDcm & nedToCigDcm () const
 get ned to cig rotation matrix
virtual const DtDcm & cigToNedDcm () const
 get cig to ned rotation matrix
virtual const DtDcm & geocToCigDcm () const
 set/get geoc to cig rotation matrix
virtual const DtDcm & cigToGeocDcm () const
 get cig to geoc rotation matrix NOTE: returns a static reference, non-reentrant
virtual const DtDcm & geocToNedDcm () const
 set/get geoc to ned rotation matrix
virtual const DtDcm & cigToEnuDcm () const
 get geoc to ned estimate rotation matrix virtual const DtDcm& geocToNedEstDcm() const;
virtual const DtDcm & nedToGeocDcm () const
 get ned to geoc rotation matrix
virtual void cigToEnu_coordTrans (const DtVector &cigPos, DtVector &enuPos) const
 convert to Enu coordinates from Cig coordinates
virtual void cigToEnu_vecTrans (const DtVector &cigVec, DtVector &enuVec) const
 convert to Enu vector from Cig vector
virtual void enuToCig_coordTrans (const DtVector &enuPos, DtVector &cigPos) const
 convert to Cig coordinates from Enu coordinates
virtual void enuToCig_vecTrans (const DtVector &enuVec, DtVector &cigVec) const
 convert to Cig vector from Enu vector NOTE: returns a static reference, non-reentrant
virtual DtVectorenuToCig_vecTrans (const DtVector &origin, const DtVector &offset) const
 provide cig coordinates given enu offset from a cig coord
virtual const DtTaitBryan & nedToCig_EulerTrans (const DtTaitBryan &topo) const
 provide cig euler angles from topo euler NOTE: returns a static reference, non-reentrant
virtual DtVector up (const DtVector &orig) const
 provide 'up' vector
virtual void topoSurface (const DtVector &o, DtVector &surface) const
 fill surface with topographic coords, alt 0

Static Public Member Functions

static DtCoordinateConvertercreate ()
static double calculateUtmLongitudeOrigin (double zone, bool useMpiDefaultOrigin=true)
static void calculateUtmLatLonOrigin (double zone, double falseOriginX, double falseOriginY, double &latitude, double &longitude, bool useMpiDefaultOrigin=true)
static int utmGridZoneFromLatLon (double latitudeInDegrees, double longitudeInDegrees)
static void setLatDtDegMinSecFromDegrees (DtDegMinSec &dmslat, double deg)
static void setLonDtDegMinSecFromDegrees (DtDegMinSec &dmslon, double deg)
static void initUtmReferencePointForZone (double longitude, bool standardOffsets, const DtMapDatum &datum, DtUtmReferencePoint &refToInitialized)
static double utmZoneToCentralMeridian (int zone)
- Static Public Member Functions inherited from makVrv::DtCoordinateConverter
static double convertToDouble (const std::string &str)
static double convertToDouble (const DtDegMinSec &dms)
static DtDegMinSec convertToDmsLat (double deg)
static DtDegMinSec convertToDmsLon (double deg)
static bool isCoordinateSystemProjected (const std::string &csType)
 Is the specified coordinate system type a projected type?

Protected Member Functions

std::string parseUtm (DtDegMinSec lat, DtDegMinSec lng, bool bUseStandardOffsets, long zone)
 Parse these Utm coords into a string rep.
- Protected Member Functions inherited from makVrv::DtCoordinateConverter
 DtCoordinateConverter (const std::string &t)
 constructor
std::string polarDirectionToStr (int dir)
 Helper for converting polar direction to string representations.
std::string parseLatLng (DtDegMinSec lat, DtDegMinSec lng)
 Return string from lat long.

Static Protected Member Functions

static void setDtDegMinSecFromDegrees (DtDegMinSec &dms, double deg)

Protected Attributes

DtUtmReferencePoint myReferencePoint
bool myUseStandardOffsets
- Protected Attributes inherited from makVrv::DtCoordinateConverter
std::string myType
 flags
bool myUsesWarbreaker
bool myZAlt
DtGeodeticCoord myGeodOrigin
 initializing system
DtDcm myNedToGeocDcm
 topo frame DCM's
DtDcm myGeocToNedDcm
DtDcm myNedToCigDcm
DtDcm myCigToNedDcm
DtDcm myGeocToCigDcm
DtDcm myCigToGeocDcm
DtDcm myCigToEnuDcm
const DtDcm myNedToEnuDcm
DtDcm myNed2CigEulerDcm
 to-euler DCM's
DtVector myLastLocation
 DtCoordTransform myGeocToNedTransform;.

Private Member Functions

 DtUtmCoordinateConverter (const DtUtmCoordinateConverter &orig)
 copy constructor
DtUtmCoordinateConverteroperator= (const DtUtmCoordinateConverter &orig)
 assignment operator

Additional Inherited Members

- Public Types inherited from makVrv::DtCoordinateConverter
typedef DtCoordinateConverter *(* CreatorFn )()
 Converts between generic Cartesian and geocentri.
- Static Public Attributes inherited from makVrv::DtCoordinateConverter
static const char * NoOp
static const char * Geocentric
 Does no conversion.
static const char * UTM
 Converts between geocentric database coords and.
static const char * Lambert
 Converts between UTM and geocentric.
static const char * FlatEarth
 Converts between Lambert and geocentric.
static const char * Cartesian
 Converts between Flat Earth and geocentric.

Detailed Description

Instances of DtUtmCoordSystem provide transformations and utilities for converting between network and UTM database coordinates.

Constructor & Destructor Documentation

makVrv::DtUtmCoordinateConverter::DtUtmCoordinateConverter ( )

default constructor

virtual makVrv::DtUtmCoordinateConverter::~DtUtmCoordinateConverter ( )
virtual

destructor

makVrv::DtUtmCoordinateConverter::DtUtmCoordinateConverter ( const DtUtmCoordinateConverter orig)
private

copy constructor

Member Function Documentation

virtual DtCoordinateConverter* makVrv::DtUtmCoordinateConverter::clone ( ) const
virtual

Clone the coordinate converter;.

Implements makVrv::DtCoordinateConverter.

virtual void makVrv::DtUtmCoordinateConverter::init ( double  lat,
double  lon,
long  zone = 0,
int  useStandardOffsets = 0 
)
virtual

Initialize converter with the origin's latitude and longitude, and an optional zone and standard offsets.

If no zone is given , the zone will be the one that contains the origin. Lat and long should be in degrees.

virtual void makVrv::DtUtmCoordinateConverter::init ( double  lat,
double  lon,
double  z,
long  zone = 0,
int  useStandardOffsets = 0 
)
virtual

Initialize converter with the origin's latitude and longitude and a z value, and an optional zone and standard offsets.

If no zone is given , the zone will be the one that contains the origin. Lat and long should be in degrees.

virtual void makVrv::DtUtmCoordinateConverter::init ( const DtGeodeticCoord &  origin,
long  zone = 0,
int  useStandardOffsets = 0 
)
virtual

Initialize converter with the origin's and an optional zone and standard offsets.

If no zone is given , the zone will be the one that contains the origin.

virtual void makVrv::DtUtmCoordinateConverter::init ( DtDegMinSec  lat,
DtDegMinSec  lon,
long  zone = 0,
int  useStandardOffsets = 0 
)
virtual

Initialize converter with the origin's latitude and longitude, and an optional zone and standard offsets.

If no zone is given , the zone will be the one that contains the origin.

virtual void makVrv::DtUtmCoordinateConverter::init ( DtDegMinSec  lat,
DtDegMinSec  lon,
double  z,
long  zone = 0,
int  useStandardOffsets = 0 
)
virtual

Initialize converter with the origin's latitude and longitude and a z-value, and an optional zone and standard offsets.

If no zone is given , the zone will be the one that contains the origin.

virtual void makVrv::DtUtmCoordinateConverter::init ( long  zone,
char  hemisphere = 'N',
bool  useMpiDefaultOrigin = true 
)
virtual

Initialize converter with the zone.

When useMpiDefaultOrigin is true, The origin will be at the equator, 500 Km west of the zone center. Otherwise, the origin will be at the equator at the center of the zone.

virtual void makVrv::DtUtmCoordinateConverter::init ( double  falseOriginX,
double  falseOriginY,
double  falseOriginZ,
long  zone,
char  hemisphere = 'N',
bool  useMpiDefaultOrigin = true 
)
virtual

Initialize converter with a false origin and zone.

When useMpiDefaultOrigin is true, The origin will be at the equator, 500 Km west of the zone center. Otherwise, the origin will be at the equator at the center of the zone.

virtual bool makVrv::DtUtmCoordinateConverter::init ( const std::string &  originstring)
virtual

Initialize converter with an origin string.

The format is "latitude,longitude,useStandardOffsets,zone", where latitude and longitude are formatted "deg:min:sec:[N|S|E|W]" and the zone is optional. For example, "35:59:59.991:N,123:0:0.131:W,0"

Implements makVrv::DtCoordinateConverter.

virtual std::string makVrv::DtUtmCoordinateConverter::stringRep ( )
virtual

Convert to string.

Implements makVrv::DtCoordinateConverter.

virtual const DtGeodeticCoord& makVrv::DtUtmCoordinateConverter::origin ( ) const
virtual

Get the origin origin is (latitude, longitude, alt) in degrees and meters (alt = 0 always)

virtual bool makVrv::DtUtmCoordinateConverter::useStandardOffsets ( ) const
virtual

Get standard offsets.

virtual long makVrv::DtUtmCoordinateConverter::zone ( ) const
virtual

Set/Get the zone.

virtual void makVrv::DtUtmCoordinateConverter::setZone ( long  zone)
virtual
virtual DtDegMinSec makVrv::DtUtmCoordinateConverter::latRef ( ) const
virtual

Get the reference latitude and longitude.

virtual DtDegMinSec makVrv::DtUtmCoordinateConverter::longRef ( ) const
virtual
virtual void makVrv::DtUtmCoordinateConverter::geocToCig ( const DtVector geoc,
DtVector out 
) const
virtual

geoc coordinates to cig coordinates

Implements makVrv::DtCoordinateConverter.

virtual const DtUtmReferencePoint* makVrv::DtUtmCoordinateConverter::referencePoint ( ) const
virtual
virtual void makVrv::DtUtmCoordinateConverter::cigToGeoc ( const DtVector in,
DtVector geoc 
) const
virtual

cig coordinates to geoc coordinates

Implements makVrv::DtCoordinateConverter.

virtual void makVrv::DtUtmCoordinateConverter::setupTopoFrame ( const DtVector truth)
virtual

Update all our transformation matrices based on the current database position.

Reimplemented from makVrv::DtCoordinateConverter.

std::string makVrv::DtUtmCoordinateConverter::parseUtm ( DtDegMinSec  lat,
DtDegMinSec  lng,
bool  bUseStandardOffsets,
long  zone 
)
protected

Parse these Utm coords into a string rep.

For example, "35:59:59.991:N,123:0:0.131:W,0,0"

static DtCoordinateConverter* makVrv::DtUtmCoordinateConverter::create ( )
static
static double makVrv::DtUtmCoordinateConverter::calculateUtmLongitudeOrigin ( double  zone,
bool  useMpiDefaultOrigin = true 
)
static
static void makVrv::DtUtmCoordinateConverter::calculateUtmLatLonOrigin ( double  zone,
double  falseOriginX,
double  falseOriginY,
double &  latitude,
double &  longitude,
bool  useMpiDefaultOrigin = true 
)
static
static int makVrv::DtUtmCoordinateConverter::utmGridZoneFromLatLon ( double  latitudeInDegrees,
double  longitudeInDegrees 
)
static
static void makVrv::DtUtmCoordinateConverter::setLatDtDegMinSecFromDegrees ( DtDegMinSec &  dmslat,
double  deg 
)
static
static void makVrv::DtUtmCoordinateConverter::setLonDtDegMinSecFromDegrees ( DtDegMinSec &  dmslon,
double  deg 
)
static
static void makVrv::DtUtmCoordinateConverter::initUtmReferencePointForZone ( double  longitude,
bool  standardOffsets,
const DtMapDatum &  datum,
DtUtmReferencePoint &  refToInitialized 
)
static
static double makVrv::DtUtmCoordinateConverter::utmZoneToCentralMeridian ( int  zone)
static
static void makVrv::DtUtmCoordinateConverter::setDtDegMinSecFromDegrees ( DtDegMinSec &  dms,
double  deg 
)
staticprotected
DtUtmCoordinateConverter& makVrv::DtUtmCoordinateConverter::operator= ( const DtUtmCoordinateConverter orig)
private

assignment operator

Member Data Documentation

DtUtmReferencePoint makVrv::DtUtmCoordinateConverter::myReferencePoint
mutableprotected
bool makVrv::DtUtmCoordinateConverter::myUseStandardOffsets
protected

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

Document ID: Generated on Mon Apr 8 19:24:01 EDT 2013 from SVN revision 125877
Copyright © 2005-2013 VT MÄK. All Rights Reserved (www.mak.com)