MrSID Decode SDK for Raster Reference Manual 9.5.4.4709

- Main Page
- Namespaces
- Classes
- Files
- Examples

- File List
- File Members

lti_geoCoord.h
Go to the documentation of this file.
1 /* $Id$ */
2 /* //////////////////////////////////////////////////////////////////////////
3 // //
4 // This code is Copyright (c) 2004 LizardTech, Inc, 1008 Western Avenue, //
5 // Suite 200, Seattle, WA 98104. Unauthorized use or distribution //
6 // prohibited. Access to and use of this code is permitted only under //
7 // license from LizardTech, Inc. Portions of the code are protected by //
8 // US and foreign patents and other filings. All Rights Reserved. //
9 // //
11 /* PUBLIC */
12
13 #ifndef LTI_GEOCOORD_H
14 #define LTI_GEOCOORD_H
15
16 // lt_lib_mrsid_core
17 #include "lti_types.h"
18
19 #include <stdlib.h>
20
21 LT_BEGIN_NAMESPACE(LizardTech)
22
23
32 class LTIGeoCoord
33 {
34 public:
48 LTIGeoCoord(double xUL, double yUL,
49 double xRes, double yRes,
50 double xRot, double yRot,
51 const char *wkt = NULL);
52
56 LTIGeoCoord();
57
61 LTIGeoCoord(const LTIGeoCoord&);
62
66 ~LTIGeoCoord();
67
71 LTIGeoCoord& operator=(const LTIGeoCoord&);
72
76 bool operator==(const LTIGeoCoord&) const;
77
81 bool operator!=(const LTIGeoCoord&) const;
82
90 double getX() const;
91
99 double getY() const;
100
108 double getXRes() const;
109
117 double getYRes() const;
118
126 double getXRot() const;
127
135 double getYRot() const;
136
144 const char *getWKT() const;
145
146
147
161 void get(double& xUL, double& yUL,
162 double& xRes, double& yRes,
163 double& xRot, double& yRot) const;
164
175 LT_STATUS pixelToGeo(double pixelX, double pixelY, double mag,
176 double &geoX, double &geoY) const;
177
188 LT_STATUS geoToPixel(double geoX, double geoY, double mag,
189 double &pixelX, double &pixelY) const;
190
200 LTIGeoCoord getGeoCoordForScene(const LTIScene &scene) const;
201
212 LTIGeoCoord scaleGeoCoord(double xMag, double yMag) const;
213
214
222 void setX(double x);
223
231 void setY(double y);
232
240 void setXRes(double xRes);
241
249 void setYRes(double yRes);
250
258 void setXRot(double xRot);
259
267 void setYRot(double yRot);
268
282 void set(double xUL, double yUL,
283 double xRes, double yRes,
284 double xRot, double yRot);
285
293 void setWKT(const char *wkt);
294
306 LT_STATUS writeWorldFile(const LTFileSpec& fileSpec,
307 bool determineExtension) const;
308
320 LT_STATUS readWorldFile(const LTFileSpec& fileSpec,
321 bool determineExtension,
322 bool& fileFound);
323
333 LT_STATUS readWorldFile(LTIOStreamInf& stream);
334
353 static LT_STATUS getWorldFileExtension(const LTFileSpec& fileSpec,
354 char* ext);
355
356
365 LT_STATUS writeMetadata(LTIMetadataDatabase &metadata) const;
366
376 LT_STATUS readMetadata(const LTIMetadataDatabase &metadata, bool &found);
377
378 bool hasRotation(void) const;
379
380 private:
381 double m_xUL;
382 double m_yUL;
383 double m_xRes;
384 double m_yRes;
385 double m_xRot;
386 double m_yRot;
387
388 char *m_wkt;
389 };
390
391 LT_END_NAMESPACE(LizardTech)
392
393
394 #endif // LTI_GEOCOORD_H

LizardTech