Cogs.Foundation
Loading...
Searching...
No Matches
Classes | Namespaces | Functions
GeodeticUtils.h File Reference
#include "../FoundationBase.h"
#include <glm/vec2.hpp>
#include <glm/vec3.hpp>
#include <glm/mat3x3.hpp>

Go to the source code of this file.

Classes

class  Cogs::LLToENUConverter
 Converts WGS latitude-longitude coordinates to ENU local tangential east-north-up coordinate system. More...
 

Namespaces

namespace  Cogs
 Main Cogs namespace.
 

Functions

COGSFOUNDATION_API void LLtoUTMZone (int &zoneNumber, bool &northernHemisphere, const double latitude, const double longitude, const int referenceEllipsoid=23)
 
COGSFOUNDATION_API void LLtoUTM (double &easting, double &northing, const double latitude, const double longitude, int zoneNumber, bool northernHemisphere, const int referenceEllipsoid=23)
 
COGSFOUNDATION_API glm::dvec3 LLtoECEF (double latitude, double longitude, double altitude=0.0)
 Converts a WGS latitude-longitude to Earth-centered, Earth-fixed (ECEF) cartesian coordinates.
 
COGSFOUNDATION_API glm::dvec2 calcUTMVectorBetweenCoordinates (double lat1, double long1, double lat2, double long2, int zone1=-1, int zone2=-1)
 Calculate a straight line vector in UTM units from lat1,long1 to lat2,long2.
 
COGSFOUNDATION_API float calcBearingBetweenCoordinates (double lat1, double long1, double lat2, double long2, int zone=-1)
 Calculate a bearing in degrees from lat1,long1 to lat2,long2.
 

Function Documentation

◆ calcBearingBetweenCoordinates()

COGSFOUNDATION_API float calcBearingBetweenCoordinates ( double  lat1,
double  long1,
double  lat2,
double  long2,
int  zone = -1 
)

Calculate a bearing in degrees from lat1,long1 to lat2,long2.

References LLtoUTMZone().

◆ calcUTMVectorBetweenCoordinates()

COGSFOUNDATION_API glm::dvec2 calcUTMVectorBetweenCoordinates ( double  lat1,
double  long1,
double  lat2,
double  long2,
int  zone1 = -1,
int  zone2 = -1 
)

Calculate a straight line vector in UTM units from lat1,long1 to lat2,long2.

References LLtoUTM(), and LLtoUTMZone().

◆ LLtoECEF()

COGSFOUNDATION_API glm::dvec3 LLtoECEF ( double  latitude,
double  longitude,
double  altitude 
)

Converts a WGS latitude-longitude to Earth-centered, Earth-fixed (ECEF) cartesian coordinates.

Converts a WGS latitude-longitude to Earth-centered, Earth-fixed (ECEF) cartesian coordinates.

https://en.wikipedia.org/wiki/Geographic_coordinate_conversion#From_geodetic_to_ECEF_coordinates *============================================================================================

Referenced by Cogs::LLToENUConverter::convert(), and Cogs::LLToENUConverter::LLToENUConverter().

◆ LLtoUTM()

COGSFOUNDATION_API void LLtoUTM ( double &  easting,
double &  northing,
const double  latitude,
const double  longitude,
int  zoneNumber,
bool  northernHemisphere,
const int  referenceEllipsoid = 23 
)

◆ LLtoUTMZone()

COGSFOUNDATION_API void LLtoUTMZone ( int &  zoneNumber,
bool &  northernHemisphere,
const double  latitude,
const double  longitude,
const int  referenceEllipsoid = 23 
)