QGIS API Documentation
4.3.0-Master (16eddb2670e)
Toggle main menu visibility
Loading...
Searching...
No Matches
src
3d
terrain
qgsterrainentity.h
Go to the documentation of this file.
1
/***************************************************************************
2
qgsterrainentity.h
3
--------------------------------------
4
Date : July 2017
5
Copyright : (C) 2017 by Martin Dobias
6
Email : wonder dot sk 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 QGSTERRAINENTITY_H
17
#define QGSTERRAINENTITY_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
31
#include <memory>
32
33
#include "
qgschunkedentity.h
"
34
#include "
qgslayerstylewatcher.h
"
35
#include "
qobjectuniqueptr.h
"
36
37
#define SIP_NO_FILE
38
39
namespace
Qt3DCore
40
{
41
class
QTransform;
42
}
43
44
class
Qgs3DMapSettings
;
45
class
QgsTerrainTextureGenerator;
46
class
QgsCoordinateTransform
;
47
class
QgsMapLayer
;
48
class
QgsTerrainGenerator
;
49
class
QgsLayerStyleWatcher;
50
56
class
QgsTerrainEntity :
public
QgsChunkedEntity
57
{
58
Q_OBJECT
59
public
:
61
explicit
QgsTerrainEntity( Qgs3DMapSettings *map, Qt3DCore::QNode *parent =
nullptr
);
62
63
~QgsTerrainEntity()
override
;
64
66
QgsTerrainTextureGenerator *textureGenerator() {
return
mTextureGenerator.get(); }
67
69
Qt3DCore::QTransform *transform()
const
{
return
mTerrainTransform; }
71
float
terrainElevationOffset()
const
;
72
73
QList<QgsRayCastHit> rayIntersection(
const
QgsRay3D &ray,
const
QgsRayCastContext &context )
const override
;
74
75
private
slots:
76
void
onShowBoundingBoxesChanged();
77
void
invalidateMapImages();
78
void
onTerrainElevationOffsetChanged();
79
80
private
:
81
std::unique_ptr<QgsTerrainTextureGenerator> mTextureGenerator;
82
Qt3DCore::QTransform *mTerrainTransform =
nullptr
;
83
84
QObjectUniquePtr<QgsLayerStyleWatcher> mLayerWatcher;
85
};
86
88
89
#endif
// QGSTERRAINENTITY_H
Qgs3DMapSettings
Definition of the world.
Definition
qgs3dmapsettings.h:59
QgsCoordinateTransform
Handles coordinate transforms between two coordinate systems.
Definition
qgscoordinatetransform.h:63
QgsMapLayer
Base class for all map layer types.
Definition
qgsmaplayer.h:83
QgsTerrainGenerator
Base class for generators of terrain.
Definition
qgsterraingenerator.h:56
Qt3DCore
Definition
qgsabstract3drenderer.h:33
qgschunkedentity.h
qgslayerstylewatcher.h
qobjectuniqueptr.h
Generated on
for QGIS API Documentation by
1.17.0