26#include <cpl_string.h>
28#include "qgis_analysis.h"
136 double calculateKernelValue(
double distance,
double bandwidth,
KernelShape shape,
OutputValues outputType )
const;
138 double uniformKernel(
double distance,
double bandwidth,
OutputValues outputType )
const;
140 double quarticKernel(
double distance,
double bandwidth,
OutputValues outputType )
const;
142 double triweightKernel(
double distance,
double bandwidth,
OutputValues outputType )
const;
144 double epanechnikovKernel(
double distance,
double bandwidth,
OutputValues outputType )
const;
146 double triangularKernel(
double distance,
double bandwidth,
OutputValues outputType )
const;
153 QString mOutputFormat;
155 int mRadiusField = -1;
156 int mWeightField = -1;
165 int mBufferSize = -1;
168 GDALRasterBandH mRasterBandH =
nullptr;
171 bool createEmptyLayer( GDALDriverH driver,
const QgsRectangle &bounds,
int rows,
int columns )
const;
172 int radiusSizeInPixels(
double radius )
const;
An interface for objects which provide features via a getFeatures method.
The feature class encapsulates a single feature including its unique ID, geometry and a list of field...
QgsKernelDensityEstimation(const Parameters ¶meters, const QString &outputFile, const QString &outputFormat)
Constructor for QgsKernelDensityEstimation.
Result run()
Runs the KDE calculation across the whole layer at once.
QgsKernelDensityEstimation(const QgsKernelDensityEstimation &other)=delete
Result addFeature(const QgsFeature &feature)
Adds a single feature to the KDE surface.
Result finalise()
Finalises the output file.
QgsKernelDensityEstimation & operator=(const QgsKernelDensityEstimation &other)=delete
KernelShape
Kernel shape type.
OutputValues
Output values type.
Result prepare()
Prepares the output file for writing and setups up the surface calculation.
Result
Result of operation.
A rectangle specified with double values.
std::unique_ptr< std::remove_pointer< GDALDatasetH >::type, GDALDatasetCloser > dataset_unique_ptr
Scoped GDAL dataset.
#define SIP_MONKEYPATCH_SCOPEENUM_UNNEST(OUTSIDE_CLASS, FORMERNAME)
#define SIP_MONKEYPATCH_COMPAT_NAME(FORMERNAME)
QgsKernelDensityEstimation::OutputValues outputValues
Type of output value.
QString radiusField
Field for radius, or empty if using a fixed radius.
double radius
Fixed radius, in map units.
QgsFeatureSource * source
Point feature source.
double decayRatio
Decay ratio (Triangular kernels only).
QgsKernelDensityEstimation::KernelShape shape
Kernel shape.
QString weightField
Field name for weighting field, or empty if not using weights.
double pixelSize
Size of pixel in output file.