QGIS API Documentation 3.41.0-Master (fda2aa46e9a)
Loading...
Searching...
No Matches
qgsvirtualpointcloudentity_p.h
Go to the documentation of this file.
1/***************************************************************************
2 qgsvirtualpointcloudentity_p.h
3 --------------------------------------
4 Date : April 2023
5 Copyright : (C) 2023 by Stefanos Natsis
6 Email : uclaros at gmail 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 QGSVIRTUALPOINTCLOUDENTITY_P_H
17#define QGSVIRTUALPOINTCLOUDENTITY_P_H
18
19#define SIP_NO_FILE
21
22//
23// W A R N I N G
24// -------------
25//
26// This file is not part of the QGIS API. It exists purely as an
27// implementation detail. This header file may change from version to
28// version without notice, or even be removed.
29//
30
32#include "qgschunkedentity.h"
33#include "qgs3dmapsceneentity.h"
34#include "qgs3drendercontext.h"
35
36class QgsAABB;
37class QgsChunkBoundsEntity;
40class QgsVirtualPointCloudProvider;
43
44
55class QgsVirtualPointCloudEntity : public Qgs3DMapSceneEntity
56{
57 Q_OBJECT
58 public:
60 QgsVirtualPointCloudEntity( Qgs3DMapSettings *map, QgsPointCloudLayer *layer, const QgsCoordinateTransform &coordinateTransform, QgsPointCloud3DSymbol *symbol, float maxScreenError, bool showBoundingBoxes,
61 double zValueScale, double zValueOffset, int pointBudget );
62
64 void handleSceneUpdate( const SceneContext &sceneContext ) override;
65
66 QgsRange<float> getNearFarPlaneRange( const QMatrix4x4 &viewMatrix ) const override;
67
68 int pendingJobsCount() const override;
69
70 bool needsUpdate() const override;
71
72 public slots:
74 void createChunkedEntityForSubIndex( int i );
75
77 void setRenderSubIndexAsBbox( int i, bool asBbox );
78
79 signals:
80 void subIndexNeedsLoading( int i );
81
82 private:
84 void updateBboxEntity();
85
87 QList<QgsChunkedEntity *> chunkedEntities() const;
88
90 QgsVirtualPointCloudProvider *provider() const;
91
93 QgsAABB boundingBox( int i ) const;
94
95 QgsPointCloudLayer *mLayer = nullptr;
96 QMap<int, QgsChunkedEntity *> mChunkedEntitiesMap;
97 QgsChunkBoundsEntity *mBboxesEntity = nullptr;
98 QList<QgsAABB> mBboxes;
99 QgsCoordinateTransform mCoordinateTransform;
100 std::unique_ptr< QgsPointCloud3DSymbol > mSymbol;
101 double mZValueScale = 1.0;
102 double mZValueOffset = 0;
103 int mPointBudget = 1000000;
104 float mMaximumScreenSpaceError = -1.;
105 bool mShowBoundingBoxes = false;
106};
107
109
110#endif // QGSVIRTUALPOINTCLOUDENTITY_P_H
Class for doing transforms between two map coordinate systems.
Represents a indexed point clouds data in octree.
Represents a map layer supporting display of point clouds.
A template based class for storing ranges (lower to upper values).
Definition qgsrange.h:46