QGIS API Documentation  3.10.0-A Coruña (6c816b4204)
qgsmesh3dsymbol_p.h
Go to the documentation of this file.
1 /***************************************************************************
2  qgsmesh3dsymbol_p.h
3  -------------------
4  Date : January 2019
5  Copyright : (C) 2019 by Peter Petrik
6  Email : zilolv 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 QGSMESH3DSYMBOL_P_H
17 #define QGSMESH3DSYMBOL_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 #include <Qt3DCore/QEntity>
31 #include <Qt3DExtras/QPhongMaterial>
32 #include <Qt3DRender/QGeometryRenderer>
33 
34 class Qgs3DMapSettings;
36 class QgsMesh3DSymbol;
37 
38 class QgsPointXY;
39 class QgsMeshLayer;
40 
42 class QgsMesh3DSymbolEntity : public Qt3DCore::QEntity
43 {
44  public:
45  QgsMesh3DSymbolEntity( const Qgs3DMapSettings &map, QgsMeshLayer *layer, const QgsMesh3DSymbol &symbol, Qt3DCore::QNode *parent = nullptr );
46 
47  private:
48  Qt3DExtras::QPhongMaterial *material( const QgsMesh3DSymbol &symbol ) const;
49 };
50 
51 class QgsMesh3DSymbolEntityNode : public Qt3DCore::QEntity
52 {
53  public:
54  QgsMesh3DSymbolEntityNode( const Qgs3DMapSettings &map, QgsMeshLayer *layer, const QgsMesh3DSymbol &symbol, Qt3DCore::QNode *parent = nullptr );
55 
56  private:
57  Qt3DRender::QGeometryRenderer *renderer( const Qgs3DMapSettings &map, const QgsMesh3DSymbol &symbol, const QgsMeshLayer *layer );
58 
59  QgsTessellatedPolygonGeometry *mGeometry = nullptr;
60 };
61 
63 
64 #endif // QGSMESH3DSYMBOL_P_H
3 3D symbol that draws mesh geometry as planar triangles.
A class to represent a 2D point.
Definition: qgspointxy.h:43
3 Definition of the world
3 Class derived from Qt3DRender::QGeometry that represents polygons tessellated into 3D geometry...
Represents a mesh layer supporting display of data on structured or unstructured meshes.
Definition: qgsmeshlayer.h:90