mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-15 00:04:00 -04:00
include gdal_version and add private constructor
This commit is contained in:
parent
9b46d9dd00
commit
88a6d2ba2f
@ -25,6 +25,8 @@ class QgsAlignRaster
|
||||
|
||||
%TypeHeaderCode
|
||||
#include "qgsalignraster.h"
|
||||
|
||||
#include <gdal_version.h>"
|
||||
%End
|
||||
public:
|
||||
QgsAlignRaster();
|
||||
@ -94,6 +96,8 @@ Get raster value at the given coordinates (from the first band)
|
||||
|
||||
protected:
|
||||
|
||||
private:
|
||||
RasterInfo( const QgsAlignRaster::RasterInfo &rh );
|
||||
};
|
||||
|
||||
|
||||
@ -125,7 +129,7 @@ filename of the source raster
|
||||
%Docstring
|
||||
filename of the newly created aligned raster (will be overwritten if exists already)
|
||||
%End
|
||||
ResampleAlg resampleMethod;
|
||||
QgsAlignRaster::ResampleAlg resampleMethod;
|
||||
%Docstring
|
||||
resampling method to be used
|
||||
%End
|
||||
|
@ -39,8 +39,11 @@ class QgsZonalStatistics
|
||||
typedef QFlags<QgsZonalStatistics::Statistic> Statistics;
|
||||
|
||||
|
||||
QgsZonalStatistics( QgsVectorLayer *polygonLayer, QgsRasterLayer *rasterLayer, const QString &attributePrefix = "", int rasterBand = 1,
|
||||
Statistics stats = Statistics( Count | Sum | Mean ) );
|
||||
QgsZonalStatistics( QgsVectorLayer *polygonLayer,
|
||||
QgsRasterLayer *rasterLayer,
|
||||
const QString &attributePrefix = "",
|
||||
int rasterBand = 1,
|
||||
QgsZonalStatistics::Statistics stats = QgsZonalStatistics::Statistics( QgsZonalStatistics::Count | QgsZonalStatistics::Sum | QgsZonalStatistics::Mean ) );
|
||||
%Docstring
|
||||
Constructor for QgsZonalStatistics.
|
||||
%End
|
||||
|
@ -40,6 +40,10 @@ typedef void *GDALDatasetH SIP_SKIP;
|
||||
*/
|
||||
class ANALYSIS_EXPORT QgsAlignRaster
|
||||
{
|
||||
#ifdef SIP_RUN
|
||||
#include <gdal_version.h>"
|
||||
#endif
|
||||
|
||||
public:
|
||||
QgsAlignRaster();
|
||||
|
||||
@ -91,6 +95,9 @@ class ANALYSIS_EXPORT QgsAlignRaster
|
||||
int mBandCnt;
|
||||
|
||||
private:
|
||||
#ifdef SIP_RUN
|
||||
RasterInfo( const QgsAlignRaster::RasterInfo &rh );
|
||||
#endif
|
||||
|
||||
friend class QgsAlignRaster;
|
||||
};
|
||||
@ -130,7 +137,7 @@ class ANALYSIS_EXPORT QgsAlignRaster
|
||||
//! filename of the newly created aligned raster (will be overwritten if exists already)
|
||||
QString outputFilename;
|
||||
//! resampling method to be used
|
||||
ResampleAlg resampleMethod;
|
||||
QgsAlignRaster::ResampleAlg resampleMethod;
|
||||
//! rescaling of values according to the change of pixel size
|
||||
bool rescaleValues;
|
||||
|
||||
|
@ -29,7 +29,7 @@
|
||||
#include <QProgressDialog>
|
||||
#include <QFile>
|
||||
|
||||
QgsZonalStatistics::QgsZonalStatistics( QgsVectorLayer *polygonLayer, QgsRasterLayer *rasterLayer, const QString &attributePrefix, int rasterBand, Statistics stats )
|
||||
QgsZonalStatistics::QgsZonalStatistics( QgsVectorLayer *polygonLayer, QgsRasterLayer *rasterLayer, const QString &attributePrefix, int rasterBand, QgsZonalStatistics::Statistics stats )
|
||||
: mRasterLayer( rasterLayer )
|
||||
, mRasterBand( rasterBand )
|
||||
, mPolygonLayer( polygonLayer )
|
||||
|
@ -59,8 +59,11 @@ class ANALYSIS_EXPORT QgsZonalStatistics
|
||||
/**
|
||||
* Constructor for QgsZonalStatistics.
|
||||
*/
|
||||
QgsZonalStatistics( QgsVectorLayer *polygonLayer, QgsRasterLayer *rasterLayer, const QString &attributePrefix = "", int rasterBand = 1,
|
||||
Statistics stats = Statistics( Count | Sum | Mean ) );
|
||||
QgsZonalStatistics( QgsVectorLayer *polygonLayer,
|
||||
QgsRasterLayer *rasterLayer,
|
||||
const QString &attributePrefix = "",
|
||||
int rasterBand = 1,
|
||||
QgsZonalStatistics::Statistics stats = QgsZonalStatistics::Statistics( QgsZonalStatistics::Count | QgsZonalStatistics::Sum | QgsZonalStatistics::Mean ) );
|
||||
|
||||
/** Starts the calculation
|
||||
\returns 0 in case of success*/
|
||||
|
Loading…
x
Reference in New Issue
Block a user