10 #if !defined(GEOGRAPHICLIB_POLYGONAREA_HPP)
11 #define GEOGRAPHICLIB_POLYGONAREA_HPP 1
17 namespace GeographicLib {
65 real _lat0, _lon0, _lat1, _lon1;
66 static inline int transit(real lon1, real lon2)
throw() {
74 lon1 < 0 && lon2 >= 0 && lon12 > 0 ? 1 :
75 (lon2 < 0 && lon1 >= 0 && lon12 < 0 ? -1 : 0);
90 , _area0(_earth.EllipsoidArea())
104 _lat0 = _lon0 = _lat1 = _lon1 = Math::NaN<real>();
116 void AddPoint(
real lat,
real lon)
throw();
128 void AddEdge(
real azi,
real s)
throw();
144 unsigned Compute(
bool reverse,
bool sign,
145 real& perimeter,
real& area)
const throw();
173 unsigned TestPoint(
real lat,
real lon,
bool reverse,
bool sign,
174 real& perimeter,
real& area)
const throw();
201 unsigned TestEdge(
real azi,
real s,
bool reverse,
bool sign,
202 real& perimeter,
real& area)
const throw();
209 unsigned TestCompute(
real lat,
real lon,
bool reverse,
bool sign,
210 real& perimeter,
real& area)
const throw() {
211 return TestPoint(lat, lon, reverse, sign, perimeter, area);
241 { lat = _lat1; lon = _lon1; }
247 #endif // GEOGRAPHICLIB_POLYGONAREA_HPP
static T AngNormalize(T x)
Math::real Flattening() const
#define GEOGRAPHICLIB_EXPORT
GeographicLib::Math::real real
void CurrentPoint(real &lat, real &lon) const
PolygonArea(const Geodesic &earth, bool polyline=false)
Header for GeographicLib::Geodesic class.
Header for GeographicLib::Accumulator class.
static T AngDiff(T x, T y)
Header for GeographicLib::Constants class.
Math::real MajorRadius() const