15#ifndef QGSHEATMAPRENDERER_H
16#define QGSHEATMAPRENDERER_H
55 QString dump() const override;
56 QSet<QString> usedAttributes( const
QgsRenderContext &context ) const override;
90 double radius()
const {
return mRadius; }
99 void setRadius(
const double radius ) { mRadius = radius; }
185 QVector<double> mValues;
187 double mCalculatedMaxValue = 0;
190 int mRadiusPixels = 0;
191 double mRadiusSquared = 0;
195 QString mWeightExpressionString;
196 int mWeightAttrNum = -1;
197 std::unique_ptr<QgsExpression> mWeightExpression;
201 double mExplicitMax = 0.0;
202 int mRenderQuality = 3;
204 int mFeaturesRendered = 0;
206 double uniformKernel(
double distance,
int bandwidth )
const;
207 double quarticKernel(
double distance,
int bandwidth )
const;
208 double triweightKernel(
double distance,
int bandwidth )
const;
209 double epanechnikovKernel(
double distance,
int bandwidth )
const;
210 double triangularKernel(
double distance,
int bandwidth )
const;
RenderUnit
Rendering size units.
@ Millimeters
Millimeters.
Abstract base class for color ramps.
Custom exception class for Coordinate Reference System related exceptions.
virtual QgsFeatureRenderer * clone() const =0
Create a deep copy of this renderer.
The feature class encapsulates a single feature including its unique ID, geometry and a list of field...
Container of fields for a vector layer.
A geometry is the spatial representation of a feature.
A renderer which draws points as a live heatmap.
QString weightExpression() const
Returns the expression used for weighting points when generating the heatmap.
QgsHeatmapRenderer & operator=(const QgsHeatmapRenderer &)=delete
Direct copies are forbidden. Use clone() instead.
void setRadius(const double radius)
Sets the radius for the heatmap.
double maximumValue() const
Returns the maximum value used for shading the heatmap.
void setRadiusUnit(const Qgis::RenderUnit unit)
Sets the units used for the heatmap's radius.
double renderQuality() const
Returns the render quality used for drawing the heatmap.
void setRenderQuality(const int quality)
Sets the render quality used for drawing the heatmap.
double radius() const
Returns the radius for the heatmap.
QgsHeatmapRenderer(const QgsHeatmapRenderer &)=delete
Direct copies are forbidden. Use clone() instead.
Qgis::RenderUnit radiusUnit() const
Returns the units used for the heatmap's radius.
void setWeightExpression(const QString &expression)
Sets the expression used for weighting points when generating the heatmap.
void setMaximumValue(const double value)
Sets the maximum value used for shading the heatmap.
const QgsMapUnitScale & radiusMapUnitScale() const
Returns the map unit scale used for the heatmap's radius.
void setRadiusMapUnitScale(const QgsMapUnitScale &scale)
Sets the map unit scale used for the heatmap's radius.
Struct for storing maximum and minimum scales for measurements in map units.
The class is used as a container of context for various read/write operations on other objects.
A rectangle specified with double values.
Contains information about the context of a rendering operation.
An interface for classes which can visit style entity (e.g.
Abstract base class for all rendered symbols.
#define SIP_THROW(name,...)
QVector< QgsPointXY > QgsMultiPointXY
A collection of QgsPoints that share a common collection of attributes.
QList< QgsSymbol * > QgsSymbolList