10#if !defined(GEOGRAPHICLIB_MGRS_HPP)
11#define GEOGRAPHICLIB_MGRS_HPP 1
18# pragma warning (push)
19# pragma warning (disable: 4251)
77 static const char*
const hemispheres_;
78 static const char*
const utmcols_[3];
79 static const char*
const utmrow_;
80 static const char*
const upscols_[4];
81 static const char*
const upsrows_[2];
82 static const char*
const latband_;
83 static const char*
const upsband_;
84 static const char*
const digits_;
85 static const char*
const alpha_;
87 static const int mineasting_[4];
88 static const int maxeasting_[4];
89 static const int minnorthing_[4];
90 static const int maxnorthing_[4];
91#if GEOGRAPHICLIB_PRECISION == 4
106 utmevenrowshift_ = 5,
111#if GEOGRAPHICLIB_PRECISION == 4
116 static void CheckCoords(
bool utmp,
bool& northp, real& x, real& y);
117 static int UTMRow(
int iband,
int icol,
int irow);
122 static int LatitudeBand(real lat) {
124 int ilat = int(floor(lat));
125 return (std::max)(-10, (std::min)(9, (ilat + 80)/8 - 10));
131 static int ApproxLatitudeBand(
real y) {
133 using std::floor;
using std::fabs;
using std::fmin;
137 int b = int(floor( ((ya * 9 + 1) / 10) / 8 ));
150 return y >= 0 ? b : -(b + 1);
153#if GEOGRAPHICLIB_PRECISION == 4
176 utmNshift_ = (maxutmSrow_ - minutmNrow_) * tile_
267 static void Forward(
int zone,
bool northp,
real x,
real y,
268 int prec, std::string& mgrs);
291 static void Forward(
int zone,
bool northp,
real x,
real y,
real lat,
292 int prec, std::string& mgrs);
339 static void Reverse(
const std::string& mgrs,
340 int& zone,
bool& northp,
real& x,
real& y,
341 int& prec,
bool centerp =
true);
366 static void Decode(
const std::string& mgrs,
367 std::string& gridzone, std::string& block,
368 std::string& easting, std::string& northing);
403# pragma warning (pop)
Header for GeographicLib::Constants class.
#define GEOGRAPHICLIB_EXPORT
GeographicLib::Math::real real
#define GEOGRAPHICLIB_PRECISION
Header for GeographicLib::UTMUPS class.
Convert between UTM/UPS and MGRS.
static Math::real EquatorialRadius()
static Math::real Flattening()
Convert between geographic coordinates and UTM/UPS.
static Math::real Flattening()
static Math::real EquatorialRadius()
Namespace for GeographicLib.