QGIS API Documentation
3.43.0-Master (c67cf405802)
Toggle main menu visibility
Main Page
Related Pages
Topics
Namespaces
Namespace List
Namespace Members
All
a
b
c
d
f
g
h
i
l
m
n
o
p
q
r
s
t
w
Functions
a
b
c
d
f
g
h
i
l
m
n
o
p
r
s
t
w
Variables
Typedefs
Enumerations
Enumerator
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
2
3
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
2
3
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Variables
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
a
b
c
d
e
f
g
h
i
k
l
m
o
p
r
s
t
u
v
w
z
Enumerations
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
z
Enumerator
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Properties
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
y
z
Related Symbols
3
a
b
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
u
v
Files
File List
File Members
All
3
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
y
z
Functions
_
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
z
Variables
a
b
c
e
f
g
h
i
l
n
o
p
q
r
s
t
w
Typedefs
3
a
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
u
v
w
Enumerations
Enumerator
Macros
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
w
y
Loading...
Searching...
No Matches
src
3d
symbols
qgslinevertexdata_p.h
Go to the documentation of this file.
1
/***************************************************************************
2
qgslinevertexdata_p.h
3
--------------------------------------
4
Date : Apr 2019
5
Copyright : (C) 2019 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 QGSLINEVERTEXDATA_P_H
17
#define QGSLINEVERTEXDATA_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 <QVector>
31
#include <QVector3D>
32
33
#define SIP_NO_FILE
34
35
#include "
qgis.h
"
36
#include "
qgs3drendercontext.h
"
37
38
39
namespace
Qt3DCore
40
{
41
class
QNode;
42
#if QT_VERSION >= QT_VERSION_CHECK( 6, 0, 0 )
43
class
QGeometry;
44
#endif
45
}
// namespace Qt3DCore
46
47
#if QT_VERSION < QT_VERSION_CHECK( 6, 0, 0 )
48
namespace
Qt3DRender
49
{
50
class
QGeometry;
51
}
52
#endif
53
54
class
QgsLineString
;
55
56
71
struct
QgsLineVertexData
72
{
73
QVector<QVector3D> vertices;
74
QVector<unsigned int> indexes;
75
QByteArray materialDataDefined;
76
77
bool
withAdjacency =
false
;
78
79
// extra info to calculate elevation
80
Qgis::AltitudeClamping
altClamping =
Qgis::AltitudeClamping::Absolute
;
81
Qgis::AltitudeBinding
altBinding =
Qgis::AltitudeBinding::Vertex
;
82
float
baseHeight = 0;
83
Qgs3DRenderContext
renderContext;
// used for altitude clamping
84
QgsVector3D
origin;
// all coordinates are relative to this origin (e.g. center of the chunk)
85
86
QgsLineVertexData();
87
88
void
init(
Qgis::AltitudeClamping
clamping,
Qgis::AltitudeBinding
binding,
float
height,
const
Qgs3DRenderContext
&renderContext,
const
QgsVector3D
&chunkOrigin );
89
90
QByteArray createVertexBuffer();
91
QByteArray createIndexBuffer();
92
#if QT_VERSION < QT_VERSION_CHECK( 6, 0, 0 )
93
Qt3DRender::QGeometry *createGeometry( Qt3DCore::QNode *parent );
94
#else
95
Qt3DCore::QGeometry *createGeometry( Qt3DCore::QNode *parent );
96
#endif
97
98
void
addLineString(
const
QgsLineString
&lineString,
float
extraHeightOffset = 0,
bool
closePolygon =
false
);
99
void
addVerticalLines(
const
QgsLineString
&lineString,
float
verticalLength,
float
extraHeightOffset = 0 );
100
};
101
103
104
#endif
// QGSLINEVERTEXDATA_P_H
Qgis::AltitudeClamping
AltitudeClamping
Altitude clamping.
Definition
qgis.h:3833
Qgis::AltitudeClamping::Absolute
@ Absolute
Elevation is taken directly from feature and is independent of terrain height (final elevation = feat...
Qgis::AltitudeBinding
AltitudeBinding
Altitude binding.
Definition
qgis.h:3846
Qgis::AltitudeBinding::Vertex
@ Vertex
Clamp every vertex of feature.
Qgs3DRenderContext
Rendering context for preparation of 3D entities.
Definition
qgs3drendercontext.h:48
QgsLineString
Line string geometry type, with support for z-dimension and m-values.
Definition
qgslinestring.h:45
QgsVector3D
A 3D vector (similar to QVector3D) with the difference that it uses double precision instead of singl...
Definition
qgsvector3d.h:30
Qt3DCore
Definition
qgsabstract3drenderer.h:31
Qt3DRender
Definition
qgs3dmapcanvas.h:35
qgis.h
qgs3drendercontext.h
Generated on Tue Apr 8 2025 15:57:40 for QGIS API Documentation by
1.9.8