The actual UTM conversion processing takes place in this helper class, which is a singleton due to the large memory footprint of the underlying PROJ.4 projections library structures. More...
Public Member Functions | |
void | ToLatLon (int zone, char band, double easting, double northing, double &latitude, double &longitude) const |
Convert UTM easting and northing to WGS84 latitude and longitude. More... | |
void | ToUtm (double latitude, double longitude, int &zone, char &band, double &easting, double &northing) const |
Convert WGS84 latitude and longitude to UTM. More... | |
void | ToUtm (double latitude, double longitude, double &easting, double &northing) const |
Convert WGS84 latitude and longitude to UTM. More... | |
~UtmData () | |
Private Member Functions | |
UtmData () | |
Private Attributes | |
projPJ | lat_lon_ |
boost::mutex | mutex_ |
projPJ | utm_north_ [60] |
projPJ | utm_south_ [60] |
Friends | |
class | boost::serialization::detail::singleton_wrapper< swri_transform_util::UtmUtil::UtmData > |
The actual UTM conversion processing takes place in this helper class, which is a singleton due to the large memory footprint of the underlying PROJ.4 projections library structures.
Thread safety is enforced with mutexes around the PROJ.4 functions, but could be achieved in the future with a thread-safe version of PROJ.4 or ignored all together if the calls can be determined to be thread safe in this context.
Definition at line 116 of file utm_util.h.
swri_transform_util::UtmUtil::UtmData::~UtmData | ( | ) |
|
private |
void swri_transform_util::UtmUtil::UtmData::ToLatLon | ( | int | zone, |
char | band, | ||
double | easting, | ||
double | northing, | ||
double & | latitude, | ||
double & | longitude | ||
) | const |
Convert UTM easting and northing to WGS84 latitude and longitude.
[in] | zone | UTM zone. |
[in] | band | UTM band. |
[in] | easting | UTM easting in meters. |
[in] | northing | UTM northing in meters. |
[out] | latitude | WGS84 latitude in degrees. |
[out] | longitude | WGS84 longitude in degrees. |
void swri_transform_util::UtmUtil::UtmData::ToUtm | ( | double | latitude, |
double | longitude, | ||
int & | zone, | ||
char & | band, | ||
double & | easting, | ||
double & | northing | ||
) | const |
Convert WGS84 latitude and longitude to UTM.
[in] | latitude | Latitude value in degrees. |
[in] | longitude | Longitude value in degrees. |
[out] | zone | UTM zone number |
[out] | band | UTM band letter |
[out] | easting | UTM easting in meters. |
[out] | northing | UTM northing in meters. |
void swri_transform_util::UtmUtil::UtmData::ToUtm | ( | double | latitude, |
double | longitude, | ||
double & | easting, | ||
double & | northing | ||
) | const |
Convert WGS84 latitude and longitude to UTM.
[in] | latitude | Latitude value in degrees. |
[in] | longitude | Longitude value in degrees. |
[out] | easting | UTM easting in meters. |
[out] | northing | UTM northing in meters. |
|
friend |
Definition at line 164 of file utm_util.h.
|
private |
Definition at line 169 of file utm_util.h.
|
mutableprivate |
Definition at line 173 of file utm_util.h.
|
private |
Definition at line 170 of file utm_util.h.
|
private |
Definition at line 171 of file utm_util.h.