1 #include <marnav/geo/position.hpp>
2 #include <marnav/math/constants.hpp>
8 position::position(const latitude
& la
, const longitude
& lo
)
14 bool position::operator==(const position
& other
) const
16 return (this == &other
) || (lat() == other
.lat() && lon() == other
.lon());
19 position
deg2rad(const position
& p
)
21 return {math::pi
/ 180.0 * p
.lat(), math::pi
/ 180.0 * p
.lon()};
24 position
rad2deg(const position
& p
)
26 return {p
.lat() / math::pi
* 180.0, p
.lon() / math::pi
* 180.0};