10 #include <matrix/coordTransform.h>
12 #include <vlutil/vlMutex.h>
15 #include <boost/enable_shared_from_this.hpp>
16 #include <boost/optional.hpp>
17 #include <boost/noncopyable.hpp>
18 #include <boost/tuple/tuple.hpp>
24 class OGRSpatialReference;
27 class SpatialReference;
30 namespace MAKVRinTerra
33 class DtFeatureGeometry;
47 typedef boost::shared_ptr<DtProj>
Ptr;
48 typedef boost::shared_ptr<const DtProj>
CPtr;
51 typedef boost::error_info<DtProj, DtProj::CPtr>
ErrorInfo;
76 : point1(p1), point2(p2) { }
83 Bounds(
const DtProj& proj,
double xmin,
double ymin,
double xmax,
double ymax);
93 const DtProj& projection()
const;
98 Bounds makeSubBounds(
unsigned x,
unsigned y,
unsigned xgrid,
unsigned ygrid)
const;
99 Bounds makeSubBounds(
unsigned n,
unsigned xgrid,
unsigned ygrid)
const;
111 std::string projString, boost::optional<AngleUnits> = boost::optional<AngleUnits>());
113 static DtProj::CPtr Make(std::auto_ptr<Coordinate_System>);
115 static DtProj::CPtr Make(
const osgEarth::SpatialReference*);
126 std::string projString()
const;
128 std::string
print()
const;
129 std::string printDetailed()
const;
132 const DtCoordTransform* transform()
const;
138 bool isLocal2D()
const;
141 bool isRectangular()
const;
143 bool isLocalTopo()
const;
145 bool inRadians()
const;
146 bool inDegrees()
const;
147 bool isLatLong()
const;
148 bool isLongLat()
const;
150 bool isGeodetic()
const;
151 bool isGeocentric()
const;
152 bool isFlatEarth()
const;
169 long count,
int offset,
double* x,
double* y,
double* z);
173 static void Convert(
const DtProj & from,
const DtProj & to, std::vector<DtPoint> & points);
174 static void Convert(
const DtProj & from,
const DtProj & to, std::list<DtPoint> & points);
199 explicit DtProj(std::string projString, boost::optional<AngleUnits>);
202 explicit DtProj(std::auto_ptr<Coordinate_System> cs);
211 boost::shared_ptr<Coordinate_System>
myCS;
#define DT_DLL_features
stop complaining about multiple independent base classes for boost::noncopyable this should probably ...
Definition: featuresDefines.h:41
void * proj
Definition: proj.h:185
DtPoint point2
Definition: proj.h:78
AngleUnits
Definition: proj.h:56
DtTaggedException< DtProj > Exception
Definition: proj.h:53
double myXmax
Definition: proj.h:104
boost::shared_ptr< ProjData > myProjData
Definition: proj.h:210
double myYmax
Definition: proj.h:105
std::string projString
Definition: proj.h:183
DT_DLL_terrainCS bool operator==(const DtDegMinSec &lhs, const DtDegMinSec &rhs)
DT_DLL_features std::ostream & operator<<(std::ostream &, const DtFeatureTransform &)
std::ostream output.
AngleOrder
Definition: proj.h:62
boost::optional< DtCoordTransform > myTransform
Definition: proj.h:214
boost::tuple< ErrorInfo, ErrorInfo > ConvertErrorInfo
Definition: proj.h:52
boost::shared_ptr< Coordinate_System > myCS
Definition: proj.h:211
Definition: coordSystem.h:54
double myYmin
Definition: proj.h:103
boost::error_info< DtProj, DtProj::CPtr > ErrorInfo
Exception stuff.
Definition: proj.h:51
boost::optional< AngleUnits > myAngleUnits
Definition: proj.h:212
Represents some coordinate system. The terms "coordinate system", "projection", "spatial reference"...
Definition: proj.h:44
boost::shared_ptr< const DtProj > CPtr
Definition: proj.h:48
Create a new MAK exception type that inherits from boost::exception. Tag is what differentiates this ...
Definition: taggedException.h:15
DtMutex mutex
Definition: proj.h:182
double myXmin
Definition: proj.h:102
DtProj::CPtr myProjection
Definition: proj.h:106
bool operator!=(const DtProj &p) const
Definition: proj.h:161
DT_DLL_terrainCS bool operator!=(const DtDegMinSec &lhs, const DtDegMinSec &rhs)
voidpf uLong offset
Definition: ioapi.h:42
boost::optional< AngleOrder > myAngleOrder
Definition: proj.h:213
Represents a feature geometry.
Definition: featureGeometry.h:39
void * context
Definition: proj.h:184
LineSegment(const DtPoint &p1, const DtPoint &p2)
Definition: proj.h:75
boost::shared_ptr< DtProj > Ptr
Definition: proj.h:47
void print(double **a, int r, int c, char *str)