18 #ifndef QGSALGORITHMCELLSTATISTICS_H
19 #define QGSALGORITHMCELLSTATISTICS_H
35 QString
group()
const final;
37 void initAlgorithm(
const QVariantMap &configuration = QVariantMap() )
final;
41 virtual void addSpecificAlgorithmParams() = 0;
47 std::vector< QgsRasterAnalysisUtils::RasterLogicInput > mInputs;
50 double mNoDataValue = -9999;
55 double mRasterUnitsPerPixelX;
56 double mRasterUnitsPerPixelY;
60 class QgsCellStatisticsAlgorithm :
public QgsCellStatisticsAlgorithmBase
63 QgsCellStatisticsAlgorithm() =
default;
65 QString svgIconPath()
const override {
return QgsApplication::iconPath( QStringLiteral(
"/algorithms/mAlgorithmCellStatistics.svg" ) ); }
66 QString name()
const override;
67 QString displayName()
const override;
68 QStringList tags()
const override;
69 QString shortHelpString()
const override;
70 QgsCellStatisticsAlgorithm *createInstance() const override
SIP_FACTORY;
73 void addSpecificAlgorithmParams() override;
78 QgsRasterAnalysisUtils::CellValueStatisticMethods mMethod;
83 class QgsCellStatisticsPercentileAlgorithm : public QgsCellStatisticsAlgorithmBase
86 QgsCellStatisticsPercentileAlgorithm() =
default;
87 QIcon icon()
const override {
return QgsApplication::getThemeIcon( QStringLiteral(
"/algorithms/mAlgorithmCellStatisticsPercentile.svg" ) ); }
88 QString svgIconPath()
const override {
return QgsApplication::iconPath( QStringLiteral(
"/algorithms/mAlgorithmCellStatisticsPercentile.svg" ) ); }
89 QString name()
const override;
90 QString displayName()
const override;
91 QStringList tags()
const override;
92 QString shortHelpString()
const override;
93 QgsCellStatisticsPercentileAlgorithm *createInstance() const override
SIP_FACTORY;
96 void addSpecificAlgorithmParams() override;
101 QgsRasterAnalysisUtils::CellValuePercentileMethods mMethod;
102 double mPercentile = 0.0;
106 class QgsCellStatisticsPercentRankFromValueAlgorithm : public QgsCellStatisticsAlgorithmBase
109 QgsCellStatisticsPercentRankFromValueAlgorithm() =
default;
110 QIcon icon()
const override {
return QgsApplication::getThemeIcon( QStringLiteral(
"/algorithms/mAlgorithmCellStatisticsPercentRank.svg" ) ); }
111 QString svgIconPath()
const override {
return QgsApplication::iconPath( QStringLiteral(
"/algorithms/mAlgorithmCellStatisticsPercentRank.svg" ) ); }
112 QString name()
const override;
113 QString displayName()
const override;
114 QStringList tags()
const override;
115 QString shortHelpString()
const override;
116 QgsCellStatisticsPercentRankFromValueAlgorithm *createInstance() const override
SIP_FACTORY;
119 void addSpecificAlgorithmParams() override;
124 QgsRasterAnalysisUtils::CellValuePercentRankMethods mMethod;
130 class QgsCellStatisticsPercentRankFromRasterAlgorithm : public QgsCellStatisticsAlgorithmBase
133 QgsCellStatisticsPercentRankFromRasterAlgorithm() =
default;
134 QIcon icon()
const override {
return QgsApplication::getThemeIcon( QStringLiteral(
"/algorithms/mAlgorithmCellStatisticsPercentRank.svg" ) ); }
135 QString svgIconPath()
const override {
return QgsApplication::iconPath( QStringLiteral(
"/algorithms/mAlgorithmCellStatisticsPercentRank.svg" ) ); }
136 QString name()
const override;
137 QString displayName()
const override;
138 QStringList tags()
const override;
139 QString shortHelpString()
const override;
140 QgsCellStatisticsPercentRankFromRasterAlgorithm *createInstance() const override
SIP_FACTORY;
143 void addSpecificAlgorithmParams() override;
148 QgsRasterAnalysisUtils::CellValuePercentRankMethods mMethod;
150 int mValueRasterBand;
157 #endif // QGSALGORITHMCELLSTATISTICS_H