![]() |
hivemind 1.0.0
|
This is the class that performs coordinate conversions. More...
#include <coordinate_converter.h>

Static Public Member Functions | |
| static void | ResetOrigin (Core::GeographicalCoordinate geoCoord, int size) |
| Sets the origin coordinate to use with relative coordinates. | |
| static Core::CartesianCoordinate | GeographicalToCartesian (Core::GeographicalCoordinate geoCoord) |
| Function used to convert a geographical coordinate to a cartesian coordinate. | |
| static Core::GeographicalCoordinate | CartesianToGeographical (Core::CartesianCoordinate cartCoord) |
| \biref Function used to convert a cartesian coordinate to a geograpical coordinate | |
| static Core::GeographicalCoordinate | GetOrigin () |
| static Core::CartesianCoordinate | SymmetricToAsymmetric (Core::CartesianCoordinate symmetric) |
| Function used to convert a coordinate in a symmetric coordinate system to a coordinate in an asymmetric coordinate system. | |
| static Core::CartesianCoordinate | AsymmetricToSymmetric (Core::CartesianCoordinate asymmetric) |
| Function used to convert a coordinate in an asymmetric cooridnate system to a coordinate in a symmetric coordinate system. | |
| static Core::UTMCoordinate | GeographicToUTM (Core::GeographicalCoordinate GeoCoord) |
| Function used to convert a geographical coordinate to a UTM coordinate. | |
| static Core::GeographicalCoordinate | UTMToGeographic (Core::UTMCoordinate UTMCoord) |
| Function used to convert a UTM coordinate to a geographical coordinate. | |
| static int | GetSize () |
Private Member Functions | |
| CoordConv () | |
| The constructor is made private to adhere to the singleton pattern. | |
Static Private Member Functions | |
| static CoordConv & | GetInstance () |
| Get the single instance of CoordConv. | |
Private Attributes | |
| Core::GeographicalCoordinate | m_OriginGeographical |
| GeographicLib::LocalCartesian | m_Origin |
| int | m_Size |
This is the class that performs coordinate conversions.
Definition at line 13 of file coordinate_converter.h.
|
inlineprivate |
The constructor is made private to adhere to the singleton pattern.
Definition at line 91 of file coordinate_converter.h.
|
static |
Function used to convert a coordinate in an asymmetric cooridnate system to a coordinate in a symmetric coordinate system.
| asymmetric | Cartesian coordinate in an asymmetric coordinate system |
Definition at line 66 of file coordinate_converter.cpp.
References GetInstance(), Core::CartesianCoordinate::X, and Core::CartesianCoordinate::Y.
Referenced by Routemaker::Routemaker::MakeRoute(), and Gui::MapViewer::mousePressEvent().


|
static |
\biref Function used to convert a cartesian coordinate to a geograpical coordinate
| cartCoord | Cartesian coordinate to convert |
Definition at line 33 of file coordinate_converter.cpp.
References GetInstance(), Core::CartesianCoordinate::X, Core::CartesianCoordinate::Y, and Core::CartesianCoordinate::Z.

|
static |
Function used to convert a geographical coordinate to a cartesian coordinate.
| geoCoord | Geograhical coordinate to convert |
Definition at line 22 of file coordinate_converter.cpp.
References GetInstance(), Core::GeographicalCoordinate::Latitude, and Core::GeographicalCoordinate::Longitude.

|
static |
Function used to convert a geographical coordinate to a UTM coordinate.
| GeoCoord | Geographical coordinate |
Definition at line 78 of file coordinate_converter.cpp.
References Core::UTMCoordinate::Easting, Core::UTMCoordinate::IsNorthHemisphere, Core::GeographicalCoordinate::Latitude, Core::GeographicalCoordinate::Longitude, Core::UTMCoordinate::Northing, and Core::UTMCoordinate::Zone.
Referenced by CompileScenario::Scenario::Scenario(), and CompileScenario::Scenario::SetOrigin().

|
inlinestaticprivate |
Get the single instance of CoordConv.
Definition at line 97 of file coordinate_converter.h.
Referenced by AsymmetricToSymmetric(), CartesianToGeographical(), GeographicalToCartesian(), GetOrigin(), GetSize(), ResetOrigin(), and SymmetricToAsymmetric().

|
static |
Definition at line 44 of file coordinate_converter.cpp.
References GetInstance().

|
inlinestatic |
Definition at line 82 of file coordinate_converter.h.
References GetInstance(), and m_Size.
Referenced by Gui::MapViewer::DrawKeyframes(), Gui::MapViewer::DrawRoutes(), and Gui::MapViewer::mousePressEvent().


|
static |
Sets the origin coordinate to use with relative coordinates.
| geoCoord | Geographical coordinate to be used as the origin of relative coordinates |
Definition at line 10 of file coordinate_converter.cpp.
References GetInstance(), Core::GeographicalCoordinate::Latitude, and Core::GeographicalCoordinate::Longitude.
Referenced by CompileScenario::Scenario::Scenario(), and CompileScenario::Scenario::SetOrigin().


|
static |
Function used to convert a coordinate in a symmetric coordinate system to a coordinate in an asymmetric coordinate system.
| symmetric | Cartesian coordinate in a symmetric coordinate system |
Definition at line 54 of file coordinate_converter.cpp.
References GetInstance(), Core::CartesianCoordinate::X, and Core::CartesianCoordinate::Y.
Referenced by Gui::MapViewer::DrawKeyframes(), Gui::MapViewer::DrawRoutes(), and Routemaker::Routemaker::MakeRoute().


|
static |
Function used to convert a UTM coordinate to a geographical coordinate.
| UTMCoord | UTM coordinate |
Definition at line 90 of file coordinate_converter.cpp.
References Core::UTMCoordinate::Easting, Core::UTMCoordinate::IsNorthHemisphere, Core::GeographicalCoordinate::Latitude, Core::GeographicalCoordinate::Longitude, Core::UTMCoordinate::Northing, and Core::UTMCoordinate::Zone.
|
private |
Definition at line 105 of file coordinate_converter.h.
|
private |
Definition at line 104 of file coordinate_converter.h.
|
private |
Definition at line 106 of file coordinate_converter.h.
Referenced by GetSize().