SLProject  4.2.000
A platform independent 3D computer graphics framework for desktop OS, Android, iOS and online in web browsers
SLLocation Class Reference

class for a named location with lat-lon-Alt WGS84 position More...

#include <SLDeviceLocation.h>

Public Member Functions

 SLLocation (string locName, int degreesLat, int minutesLat, double secondsLat, int degreesLon, int minutesLon, double secondsLon, double altitudeM)
 SLLocation contructor with WGS84 position in deg, min. & sec. More...
 
 SLLocation (string locName, SLVec3d posWGS84)
 SLLocation contructor with decimal pos in WGS84. More...
 

Public Attributes

string name
 
SLVec3d posWGS84LatLonAlt
 

Detailed Description

class for a named location with lat-lon-Alt WGS84 position

Definition at line 23 of file SLDeviceLocation.h.

Constructor & Destructor Documentation

◆ SLLocation() [1/2]

SLLocation::SLLocation ( string  locName,
int  degreesLat,
int  minutesLat,
double  secondsLat,
int  degreesLon,
int  minutesLon,
double  secondsLon,
double  altitudeM 
)
inline

SLLocation contructor with WGS84 position in deg, min. & sec.

Definition at line 27 of file SLDeviceLocation.h.

35  {
36  name = std::move(locName);
37  SLVec3d posWGS84 = SLAlgo::geoDegMinSec2Decimal(degreesLat,
38  minutesLat,
39  secondsLat,
40  degreesLon,
41  minutesLon,
42  secondsLon,
43  altitudeM);
44  posWGS84LatLonAlt.set(posWGS84.lat,
45  posWGS84.lon,
46  posWGS84.alt);
47  }
SLVec3d posWGS84LatLonAlt
T lat
Definition: SLVec3.h:45
T alt
Definition: SLVec3.h:45
void set(const T X, const T Y, const T Z)
Definition: SLVec3.h:59
T lon
Definition: SLVec3.h:45
T geoDegMinSec2Decimal(int degrees, int minutes, T seconds)
convert geodetic datum defined in degrees, minutes and seconds to decimal
Definition: SLAlgo.cpp:45

◆ SLLocation() [2/2]

SLLocation::SLLocation ( string  locName,
SLVec3d  posWGS84 
)
inline

SLLocation contructor with decimal pos in WGS84.

Definition at line 50 of file SLDeviceLocation.h.

51  {
52  name = std::move(locName);
53  posWGS84LatLonAlt.set(posWGS84.lat,
54  posWGS84.lon,
55  posWGS84.alt);
56  }

Member Data Documentation

◆ name

string SLLocation::name

Definition at line 58 of file SLDeviceLocation.h.

◆ posWGS84LatLonAlt

SLVec3d SLLocation::posWGS84LatLonAlt

Definition at line 59 of file SLDeviceLocation.h.


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