RTAB-Map 0.23.10
Real-Time Appearance-Based Mapping
Loading...
Searching...
No Matches
rtabmap::GeodeticCoords Class Reference

WGS84 geodetic latitude, longitude and altitude with coordinate conversions. More...

#include <GeodeticCoords.h>

Public Member Functions

 GeodeticCoords ()
 Default-constructs coordinates at (0°, 0°, 0 m).
 
 GeodeticCoords (double latitude, double longitude, double altitude)
 Constructs geodetic coordinates.
 
const double & latitude () const
 
const double & longitude () const
 
const double & altitude () const
 
void setLatitude (const double &value)
 Sets latitude in decimal degrees.
 
void setLongitude (const double &value)
 Sets longitude in decimal degrees.
 
void setAltitude (const double &value)
 Sets altitude in meters.
 
cv::Point3d toGeocentric_WGS84 () const
 
cv::Point3d toENU_WGS84 (const GeodeticCoords &origin) const
 
void fromGeocentric_WGS84 (const cv::Point3d &geocentric)
 Sets this point from ECEF geocentric geocentric coordinates.
 
void fromENU_WGS84 (const cv::Point3d &enu, const GeodeticCoords &origin)
 Sets this point from an ENU offset relative to origin.
 

Static Public Member Functions

static cv::Point3d ENU_WGS84ToGeocentric_WGS84 (const cv::Point3d &enu, const GeodeticCoords &origin)
 
static cv::Point3d Geocentric_WGS84ToENU_WGS84 (const cv::Point3d &geocentric_WGS84, const cv::Point3d &origin_geocentric_WGS84, const GeodeticCoords &origin)
 

Detailed Description

WGS84 geodetic latitude, longitude and altitude with coordinate conversions.

Conversions follow the WGS84 reference ellipsoid (MRPT-derived implementation). ENU frames use east = X, north = Y, up = Z relative to a local origin.

See also
GPS::toGeodeticCoords()

Definition at line 61 of file GeodeticCoords.h.

Constructor & Destructor Documentation

◆ GeodeticCoords()

rtabmap::GeodeticCoords::GeodeticCoords ( double  latitude,
double  longitude,
double  altitude 
)

Constructs geodetic coordinates.

Parameters
latitudeLatitude in decimal degrees (DD, north positive).
longitudeLongitude in decimal degrees (DD, east positive).
altitudeAltitude in meters above the WGS84 ellipsoid.

Member Function Documentation

◆ latitude()

const double & rtabmap::GeodeticCoords::latitude ( ) const
inline
Returns
Latitude in decimal degrees.

Definition at line 75 of file GeodeticCoords.h.

◆ longitude()

const double & rtabmap::GeodeticCoords::longitude ( ) const
inline
Returns
Longitude in decimal degrees.

Definition at line 77 of file GeodeticCoords.h.

◆ altitude()

const double & rtabmap::GeodeticCoords::altitude ( ) const
inline
Returns
Altitude in meters.

Definition at line 79 of file GeodeticCoords.h.

◆ setLatitude()

void rtabmap::GeodeticCoords::setLatitude ( const double &  value)
inline

Sets latitude in decimal degrees.

Definition at line 82 of file GeodeticCoords.h.

◆ setLongitude()

void rtabmap::GeodeticCoords::setLongitude ( const double &  value)
inline

Sets longitude in decimal degrees.

Definition at line 84 of file GeodeticCoords.h.

◆ setAltitude()

void rtabmap::GeodeticCoords::setAltitude ( const double &  value)
inline

Sets altitude in meters.

Definition at line 86 of file GeodeticCoords.h.

◆ toGeocentric_WGS84()

cv::Point3d rtabmap::GeodeticCoords::toGeocentric_WGS84 ( ) const
Returns
ECEF geocentric coordinates (meters) in the WGS84 frame.

◆ toENU_WGS84()

cv::Point3d rtabmap::GeodeticCoords::toENU_WGS84 ( const GeodeticCoords origin) const
Returns
ENU offset (meters) from origin to this point. East = X, north = Y, up = Z.

◆ ENU_WGS84ToGeocentric_WGS84()

static cv::Point3d rtabmap::GeodeticCoords::ENU_WGS84ToGeocentric_WGS84 ( const cv::Point3d &  enu,
const GeodeticCoords origin 
)
static
Returns
ECEF geocentric coordinates of ENU point enu relative to origin.

◆ Geocentric_WGS84ToENU_WGS84()

static cv::Point3d rtabmap::GeodeticCoords::Geocentric_WGS84ToENU_WGS84 ( const cv::Point3d &  geocentric_WGS84,
const cv::Point3d &  origin_geocentric_WGS84,
const GeodeticCoords origin 
)
static
Returns
ENU offset from geocentric origin_geocentric_WGS84 to geocentric_WGS84.
Parameters
originGeodetic origin used to define the local ENU basis.

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