QGIS API Documentation 3.99.0-Master (8e76e220402)
Loading...
Searching...
No Matches
qgsmapoverlaytexturegenerator_p.h
Go to the documentation of this file.
1/***************************************************************************
2 qgsmapoverlaytexturegenerator_p.h
3 --------------------------------------
4 Date : July 2025
5 Copyright : (C) 2025 by Jean Felder
6 Email : jean dot felder at oslandia dot com
7 ***************************************************************************
8 * *
9 * This program is free software; you can redistribute it and/or modify *
10 * it under the terms of the GNU General Public License as published by *
11 * the Free Software Foundation; either version 2 of the License, or *
12 * (at your option) any later version. *
13 * *
14 ***************************************************************************/
15
16#ifndef QGSMAPOVERLAYTEXTUREGENERATOR_P_H
17#define QGSMAPOVERLAYTEXTUREGENERATOR_P_H
18
20
21//
22// W A R N I N G
23// -------------
24//
25// This file is not part of the QGIS API. It exists purely as an
26// implementation detail. This header file may change from version to
27// version without notice, or even be removed.
28//
29
30#define SIP_NO_FILE
31
32#include "qgsrectangle.h"
33
34#include <QObject>
35
38class QgsMapSettings;
39class QgsProject;
40class QgsRasterLayer;
41
51class QgsMapOverlayTextureGenerator : public QObject
52{
53 Q_OBJECT
54 public:
56 QgsMapOverlayTextureGenerator( const Qgs3DMapSettings &mapSettings, int size );
57
58 ~QgsMapOverlayTextureGenerator() override;
59
64 int render( const QgsRectangle &extent, const QVector<QgsPointXY> &frustumExtent, double azimuthDegrees, bool showFrustum = false );
65
67 void cancelActiveJob();
68
70 void waitForFinished();
71
72 signals:
74 void textureReady( const QImage &image );
75
76 private slots:
77 void onRenderingFinished();
78
79 private:
80 QgsMapSettings baseMapSettings() const;
81
82 const Qgs3DMapSettings &m3DMapSettings;
83 QSize mSize;
84 QgsMapRendererParallelJob *mActiveJob = nullptr;
85 QgsRectangle mExtent;
86 double mRotation = 0.;
87 QVector<QgsPointXY> mFrustumExtent;
88 bool mShowFrustum = false;
89 int mLastJobId = 0;
90};
91
93
94#endif // QGSMAPOVERLAYTEXTUREGENERATOR_P_H
Definition of the world.
Job implementation that renders all layers in parallel.
Contains configuration for rendering maps.
Encapsulates a QGIS project, including sets of map layers and their styles, layouts,...
Definition qgsproject.h:113
Represents a raster layer.