QGIS API Documentation 3.41.0-Master (cea29feecf2)
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, double zValueScale, double zValueOffset, int pointBudget );
61
63 void handleSceneUpdate( const SceneContext &sceneContext ) override;
64
65 QgsRange<float> getNearFarPlaneRange( const QMatrix4x4 &viewMatrix ) const override;
66
67 int pendingJobsCount() const override;
68
69 bool needsUpdate() const override;
70
71 public slots:
73 void createChunkedEntityForSubIndex( int i );
74
76 void setRenderSubIndexAsBbox( int i, bool asBbox );
77
78 signals:
79 void subIndexNeedsLoading( int i );
80
81 private:
83 void updateBboxEntity();
84
86 QList<QgsChunkedEntity *> chunkedEntities() const;
87
89 QgsVirtualPointCloudProvider *provider() const;
90
92 QgsAABB boundingBox( int i ) const;
93
94 QgsPointCloudLayer *mLayer = nullptr;
95 QMap<int, QgsChunkedEntity *> mChunkedEntitiesMap;
96 QgsChunkBoundsEntity *mBboxesEntity = nullptr;
97 QList<QgsAABB> mBboxes;
98 QgsCoordinateTransform mCoordinateTransform;
99 std::unique_ptr<QgsPointCloud3DSymbol> mSymbol;
100 double mZValueScale = 1.0;
101 double mZValueOffset = 0;
102 int mPointBudget = 1000000;
103 float mMaximumScreenSpaceError = -1.;
104 bool mShowBoundingBoxes = false;
105};
106
108
109#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