2017-06-06 11:03:05 +02:00
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
2017-08-06 13:39:03 +02:00
|
|
|
* src/core/symbology/qgsheatmaprenderer.h *
|
2017-06-06 11:03:05 +02:00
|
|
|
* *
|
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
|
|
************************************************************************/
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-08-06 11:01:42 +02:00
|
|
|
class QgsHeatmapRenderer : QgsFeatureRenderer
|
2014-11-22 13:03:54 +11:00
|
|
|
{
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2018-05-26 14:10:30 +10:00
|
|
|
A renderer which draws points as a live heatmap
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-06-06 11:03:05 +02:00
|
|
|
.. versionadded:: 2.7
|
|
|
|
%End
|
|
|
|
|
2014-11-22 13:03:54 +11:00
|
|
|
%TypeHeaderCode
|
2017-06-06 11:03:05 +02:00
|
|
|
#include "qgsheatmaprenderer.h"
|
2014-11-22 13:03:54 +11:00
|
|
|
%End
|
|
|
|
public:
|
|
|
|
|
|
|
|
QgsHeatmapRenderer();
|
2017-12-15 08:57:22 +10:00
|
|
|
~QgsHeatmapRenderer();
|
2014-11-22 13:03:54 +11:00
|
|
|
|
2017-06-06 11:03:05 +02:00
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
virtual QgsHeatmapRenderer *clone() const /Factory/;
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
virtual void startRender( QgsRenderContext &context, const QgsFields &fields );
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2018-04-18 13:16:33 +02:00
|
|
|
virtual bool renderFeature( const QgsFeature &feature, QgsRenderContext &context, int layer = -1, bool selected = false, bool drawVertexMarker = false );
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
virtual void stopRender( QgsRenderContext &context );
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2018-04-18 13:16:33 +02:00
|
|
|
virtual QgsSymbol *symbolForFeature( const QgsFeature &feature, QgsRenderContext &context ) const;
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-06-06 11:03:05 +02:00
|
|
|
.. note::
|
|
|
|
|
|
|
|
symbolForFeature2 in Python bindings
|
|
|
|
%End
|
2018-04-18 12:51:48 +02:00
|
|
|
virtual QgsSymbolList symbols( QgsRenderContext &context ) const;
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-06-06 11:03:05 +02:00
|
|
|
.. note::
|
|
|
|
|
|
|
|
symbol2 in Python bindings
|
|
|
|
%End
|
2014-11-22 13:03:54 +11:00
|
|
|
virtual QString dump() const;
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2017-06-06 11:03:05 +02:00
|
|
|
virtual QSet<QString> usedAttributes( const QgsRenderContext &context ) const;
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2017-06-06 11:03:05 +02:00
|
|
|
static QgsFeatureRenderer *create( QDomElement &element, const QgsReadWriteContext &context ) /Factory/;
|
|
|
|
%Docstring
|
|
|
|
Creates a new heatmap renderer instance from XML
|
|
|
|
%End
|
|
|
|
virtual QDomElement save( QDomDocument &doc, const QgsReadWriteContext &context );
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2017-06-06 11:03:05 +02:00
|
|
|
static QgsHeatmapRenderer *convertFromRenderer( const QgsFeatureRenderer *renderer ) /Factory/;
|
2014-11-22 13:03:54 +11:00
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
virtual void modifyRequestExtent( QgsRectangle &extent, QgsRenderContext &context );
|
2014-11-22 13:03:54 +11:00
|
|
|
|
|
|
|
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
QgsColorRamp *colorRamp() const;
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the color ramp used for shading the heatmap.
|
|
|
|
|
|
|
|
:return: color ramp for heatmap
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setColorRamp`
|
2017-06-06 11:03:05 +02:00
|
|
|
%End
|
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
void setColorRamp( QgsColorRamp *ramp /Transfer/ );
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the color ramp to use for shading the heatmap.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param ramp: color ramp for heatmap. Ownership of ramp is transferred to the renderer.
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`colorRamp`
|
2017-06-06 11:03:05 +02:00
|
|
|
%End
|
2014-11-30 10:26:17 +01:00
|
|
|
|
2014-11-22 13:03:54 +11:00
|
|
|
double radius() const;
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the radius for the heatmap
|
|
|
|
|
|
|
|
:return: heatmap radius
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setRadius`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`radiusUnit`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`radiusMapUnitScale`
|
2017-06-06 11:03:05 +02:00
|
|
|
%End
|
|
|
|
|
2014-11-22 13:03:54 +11:00
|
|
|
void setRadius( const double radius );
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the radius for the heatmap
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param radius: heatmap radius
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`radius`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setRadiusUnit`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setRadiusMapUnitScale`
|
2017-06-06 11:03:05 +02:00
|
|
|
%End
|
2014-11-22 13:03:54 +11:00
|
|
|
|
2016-07-17 22:11:17 +10:00
|
|
|
QgsUnitTypes::RenderUnit radiusUnit() const;
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the units used for the heatmap's radius
|
|
|
|
|
|
|
|
:return: units for heatmap radius
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`radius`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setRadiusUnit`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`radiusMapUnitScale`
|
2017-06-06 11:03:05 +02:00
|
|
|
%End
|
|
|
|
|
2016-07-17 22:11:17 +10:00
|
|
|
void setRadiusUnit( const QgsUnitTypes::RenderUnit unit );
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the units used for the heatmap's radius
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param unit: units for heatmap radius
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`radiusUnit`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setRadius`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`radiusMapUnitScale`
|
2017-06-06 11:03:05 +02:00
|
|
|
%End
|
2014-11-22 13:03:54 +11:00
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
const QgsMapUnitScale &radiusMapUnitScale() const;
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the map unit scale used for the heatmap's radius
|
|
|
|
|
|
|
|
:return: map unit scale for heatmap's radius
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`radius`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`radiusUnit`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setRadiusMapUnitScale`
|
2017-06-06 11:03:05 +02:00
|
|
|
%End
|
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
void setRadiusMapUnitScale( const QgsMapUnitScale &scale );
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the map unit scale used for the heatmap's radius
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param scale: map unit scale for heatmap's radius
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setRadius`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setRadiusUnit`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`radiusMapUnitScale`
|
2017-06-06 11:03:05 +02:00
|
|
|
%End
|
2014-11-22 13:03:54 +11:00
|
|
|
|
|
|
|
double maximumValue() const;
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the maximum value used for shading the heatmap.
|
|
|
|
|
|
|
|
:return: maximum value for heatmap shading. If 0, then maximum value will be automatically
|
2018-05-24 21:21:14 +10:00
|
|
|
calculated.
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setMaximumValue`
|
2017-06-06 11:03:05 +02:00
|
|
|
%End
|
|
|
|
|
2014-11-22 13:03:54 +11:00
|
|
|
void setMaximumValue( const double value );
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the maximum value used for shading the heatmap.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param value: maximum value for heatmap shading. Set to 0 for automatic calculation of
|
2018-05-24 21:21:14 +10:00
|
|
|
maximum value.
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`maximumValue`
|
2017-06-06 11:03:05 +02:00
|
|
|
%End
|
2014-11-22 13:03:54 +11:00
|
|
|
|
|
|
|
double renderQuality() const;
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the render quality used for drawing the heatmap.
|
|
|
|
|
|
|
|
:return: render quality. A value of 1 indicates maximum quality, and increasing the
|
2018-05-24 21:21:14 +10:00
|
|
|
value will result in faster drawing but lower quality rendering.
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setRenderQuality`
|
2017-06-06 11:03:05 +02:00
|
|
|
%End
|
|
|
|
|
2014-11-22 13:03:54 +11:00
|
|
|
void setRenderQuality( const int quality );
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the render quality used for drawing the heatmap.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param quality: render quality. A value of 1 indicates maximum quality, and increasing the
|
2018-05-24 21:21:14 +10:00
|
|
|
value will result in faster drawing but lower quality rendering.
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`renderQuality`
|
2017-06-06 11:03:05 +02:00
|
|
|
%End
|
2014-11-30 10:26:17 +01:00
|
|
|
|
2014-11-23 21:47:58 +11:00
|
|
|
QString weightExpression() const;
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the expression used for weighting points when generating the heatmap.
|
|
|
|
|
|
|
|
:return: point weight expression. If empty, all points are equally weighted.
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setWeightExpression`
|
2017-06-06 11:03:05 +02:00
|
|
|
%End
|
2014-11-23 21:47:58 +11:00
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
void setWeightExpression( const QString &expression );
|
2017-06-06 11:03:05 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the expression used for weighting points when generating the heatmap.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param expression: point weight expression. If set to empty, all points are equally weighted.
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`weightExpression`
|
2017-06-06 11:03:05 +02:00
|
|
|
%End
|
2014-11-22 13:03:54 +11:00
|
|
|
|
|
|
|
};
|
2017-06-06 11:03:05 +02:00
|
|
|
|
|
|
|
|
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
2017-08-06 13:39:03 +02:00
|
|
|
* src/core/symbology/qgsheatmaprenderer.h *
|
2017-06-06 11:03:05 +02:00
|
|
|
* *
|
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
|
|
************************************************************************/
|