18#ifndef QGSTILEDSCENERENDERER_H
19#define QGSTILEDSCENERENDERER_H
72 QImage textureImage()
const;
79 void setTextureImage(
const QImage &image );
86 void setTextureCoordinates(
87 float textureX1,
float textureY1,
88 float textureX2,
float textureY2,
89 float textureX3,
float textureY3
106 QImage mTextureImage;
107 float mTextureCoordinates[6] { 0, 0, 0, 0, 0, 0 };
125 const QString type = sipCpp->
type();
126 if ( type == QLatin1String(
"texture" ) )
127 sipType = sipType_QgsTiledSceneTextureRenderer;
128 else if ( type == QLatin1String(
"wireframe" ) )
129 sipType = sipType_QgsTiledSceneWireframeRenderer;
145 virtual QString
type()
const = 0;
189 double maximumScreenError()
const;
201 void setMaximumScreenError(
double error );
264 virtual QStringList legendRuleKeys()
const;
289 void restoreCommonProperties(
const QDomElement &element,
const QgsReadWriteContext &context );
297 void saveCommonProperties( QDomElement &element,
const QgsReadWriteContext &context )
const;
306 QThread *mThread =
nullptr;
309 double mMaximumScreenError = 3;
311 bool mTileBorderRendering =
false;
RenderUnit
Rendering size units.
@ Millimeters
Millimeters.
QFlags< TiledSceneRendererFlag > TiledSceneRendererFlags
Flags which control how tiled scene 2D renderers behave.
Base class for feedback objects to be used for cancellation of something running in a worker thread.
Layer tree node points to a map layer.
The QgsLegendRendererItem class is abstract interface for legend items returned from QgsMapLayerLegen...
The class is used as a container of context for various read/write operations on other objects.
Contains information about the context of a rendering operation.
Encapsulates the render context for a 2D tiled scene rendering operation.
QgsFeedback * feedback() const
Returns the feedback object used to cancel rendering.
QgsTiledSceneRenderContext & operator=(const QgsTiledSceneRenderContext &)=delete
QgsRenderContext & renderContext()
Returns a reference to the context's render context.
QgsTiledSceneRenderContext(const QgsTiledSceneRenderContext &rh)=delete
const QgsRenderContext & renderContext() const
Returns a reference to the context's render context.
Abstract base class for 2d tiled scene renderers.
void setTileBorderRenderingEnabled(bool enabled)
Sets whether to render the borders of tiles.
virtual QString type() const =0
Returns the identifier of the renderer type.
QgsTiledSceneRenderer(const QgsTiledSceneRenderer &other)=delete
QgsTiledSceneRenderer cannot be copied – use clone() instead.
virtual QDomElement save(QDomDocument &doc, const QgsReadWriteContext &context) const =0
Saves the renderer configuration to an XML element.
virtual ~QgsTiledSceneRenderer()=default
virtual QgsTiledSceneRenderer * clone() const =0
Create a deep copy of this renderer.
QgsTiledSceneRenderer()=default
QgsTiledSceneRenderer & operator=(const QgsTiledSceneRenderer &other)=delete
QgsTiledSceneRenderer cannot be copied – use clone() instead.
virtual void renderTriangle(QgsTiledSceneRenderContext &context, const QPolygonF &triangle)=0
Renders a triangle.
virtual void renderLine(QgsTiledSceneRenderContext &context, const QPolygonF &line)=0
Renders a line.
bool isTileBorderRenderingEnabled() const
Returns whether to render also borders of tiles.
#define SIP_CONVERT_TO_SUBCLASS_CODE(code)