16 #ifndef QGSDISTANCEAREA_H
17 #define QGSDISTANCEAREA_H
50 void setEllipsoidalMode(
bool flag );
56 void setSourceCrs(
long srsid );
65 void setSourceAuthId( QString authid );
70 bool geographic()
const {
return mCoordTransform->sourceCrs().geographicFlag(); }
73 bool setEllipsoid(
const QString& ellipsoid );
77 bool setEllipsoid(
double semiMajor,
double semiMinor );
80 const QString&
ellipsoid()
const {
return mEllipsoid; }
96 double measureLine(
const QList<QgsPoint>& points );
102 double measurePolygon(
const QList<QgsPoint>& points );
107 static QString textUnit(
double value,
int decimals,
QGis::UnitType u,
bool isArea,
bool keepBaseUnit =
false );
114 const unsigned char* measureLine(
const unsigned char* feature,
double* area,
bool hasZptr =
false );
116 const unsigned char* measurePolygon(
const unsigned char* feature,
double* area,
double* perimeter,
bool hasZptr =
false );
129 double* course1 = NULL,
double* course2 = NULL );
137 double computePolygonArea(
const QList<QgsPoint>& points );
139 double computePolygonFlatArea(
const QList<QgsPoint>& points );
145 void computeAreaInit();
168 double getQ(
double x );
169 double getQbar(
double x );