17 #ifndef QGSCOORDINATETRANSFORM_H 18 #define QGSCOORDINATETRANSFORM_H 20 #include <QExplicitlySharedDataPointer> 22 #include "qgsconfig.h" 23 #include "qgis_core.h" 28 class QgsCoordinateTransformPrivate;
137 int sourceDatumTransformId,
138 int destinationDatumTransformId );
157 bool isValid()
const;
245 void transformInPlace(
double &x,
double &y,
double &z,
TransformDirection direction = ForwardTransform )
const;
287 void transformInPlace( QVector<float> &x, QVector<float> &y, QVector<float> &z,
302 void transformInPlace( QVector<double> &x, QVector<double> &y, QVector<double> &z,
310 void transformPolygon( QPolygonF &polygon,
TransformDirection direction = ForwardTransform )
const;
332 void transformCoords(
int numPoint,
double *x,
double *y,
double *z,
TransformDirection direction = ForwardTransform )
const;
337 bool isShortCircuited()
const;
351 int sourceDatumTransformId()
const;
365 void setSourceDatumTransformId(
int datumId );
379 int destinationDatumTransformId()
const;
393 void setDestinationDatumTransformId(
int datumId );
401 static void invalidateCache();
405 mutable QExplicitlySharedDataPointer<QgsCoordinateTransformPrivate> d;
411 bool mHasContext =
false;
416 int srcDatumTransform,
417 int destDatumTransform );
421 static QReadWriteLock sCacheLock;
430 QString mySummary( QStringLiteral(
"\n%%%%%%%%%%%%%%%%%%%%%%%%\nCoordinate Transform def begins:" ) );
431 mySummary += QLatin1String(
"\n\tInitialized? : " );
447 mySummary +=
"\n\tShort Circuit? : ";
457 mySummary +=
"\n\tSource Spatial Ref Sys : ";
464 mySummary +=
"Undefined";
467 mySummary +=
"\n\tDest Spatial Ref Sys : ";
470 mySummary << r.destCRS();
474 mySummary +=
"Undefined";
478 mySummary += QLatin1String(
"\nCoordinate Transform def ends \n%%%%%%%%%%%%%%%%%%%%%%%%\n" );
479 return os << mySummary.toLocal8Bit().data() << std::endl;
484 #endif // QGSCOORDINATETRANSFORM_H A rectangle specified with double values.
A class to represent a 2D point.
Reads and writes project states.
Contains information about the context in which a coordinate transform is executed.
This class represents a coordinate reference system (CRS).