Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Toggle main menu visibility
Loading...
Searching...
No Matches
qwavefrontmesh_p.h
Go to the documentation of this file.
1
// Copyright (C) 2018 The Qt Company Ltd.
2
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
// Qt-Security score:significant reason:default
4
5
#
ifndef
QWAVEFRONTMESH_P_H
6
#
define
QWAVEFRONTMESH_P_H
7
8
//
9
// W A R N I N G
10
// -------------
11
//
12
// This file is not part of the Qt API. It exists purely as an
13
// implementation detail. This header file may change from version to
14
// version without notice, or even be removed.
15
//
16
// We mean it.
17
//
18
19
#
include
"qqmlwavefrontmeshglobal_p.h"
20
21
#
include
<
QtQuick
/
private
/
qquickshadereffectmesh_p
.
h
>
22
23
#
include
<
QtCore
/
qurl
.
h
>
24
#
include
<
QtGui
/
qvector3d
.
h
>
25
26
QT_BEGIN_NAMESPACE
27
28
class
QWavefrontMeshPrivate;
29
class
Q_LABSWAVEFRONTMESH_EXPORT
QWavefrontMesh
:
public
QQuickShaderEffectMesh
30
{
31
Q_OBJECT
32
Q_PROPERTY(QUrl source READ source WRITE setSource NOTIFY sourceChanged FINAL)
33
Q_PROPERTY(Error lastError READ lastError NOTIFY lastErrorChanged FINAL)
34
Q_PROPERTY(QVector3D projectionPlaneV READ projectionPlaneV WRITE setProjectionPlaneV NOTIFY projectionPlaneVChanged FINAL)
35
Q_PROPERTY(QVector3D projectionPlaneW READ projectionPlaneW WRITE setProjectionPlaneW NOTIFY projectionPlaneWChanged FINAL)
36
QML_NAMED_ELEMENT(WavefrontMesh)
37
QML_ADDED_IN_VERSION(1, 0)
38
39
public
:
40
enum
Error {
41
NoError,
42
InvalidSourceError,
43
UnsupportedFaceShapeError,
44
UnsupportedIndexSizeError,
45
FileNotFoundError,
46
NoAttributesError,
47
MissingPositionAttributeError,
48
MissingTextureCoordinateAttributeError,
49
MissingPositionAndTextureCoordinateAttributesError,
50
TooManyAttributesError,
51
InvalidPlaneDefinitionError
52
};
53
Q_ENUM(Error)
54
55
QWavefrontMesh(QObject *parent =
nullptr
);
56
~QWavefrontMesh() override;
57
58
QUrl source()
const
;
59
void
setSource(
const
QUrl &url);
60
61
Error lastError()
const
;
62
void
setLastError(Error lastError);
63
64
bool
validateAttributes(
const
QList<QByteArray> &attributes,
int
*posIndex) override;
65
QSGGeometry *updateGeometry(QSGGeometry *geometry,
int
attrCount,
int
posIndex,
66
const
QRectF &srcRect,
const
QRectF &rect) override;
67
QString log()
const
override;
68
69
QVector3D projectionPlaneV()
const
;
70
void
setProjectionPlaneV(
const
QVector3D &projectionPlaneV);
71
72
QVector3D projectionPlaneW()
const
;
73
void
setProjectionPlaneW(
const
QVector3D &projectionPlaneW);
74
75
Q_SIGNALS:
76
void
sourceChanged();
77
void
lastErrorChanged();
78
void
projectionPlaneVChanged();
79
void
projectionPlaneWChanged();
80
81
protected
Q_SLOTS:
82
void
readData();
83
84
private
:
85
Q_DISABLE_COPY(QWavefrontMesh)
86
Q_DECLARE_PRIVATE(QWavefrontMesh)
87
};
88
89
QT_END_NAMESPACE
90
91
#
endif
// QWAVEFRONTMESH_P_H
QWavefrontMeshPrivate
Definition
qwavefrontmesh.cpp:22
QWavefrontMeshPrivate::vertexes
QList< QVector3D > vertexes
Definition
qwavefrontmesh.cpp:41
QWavefrontMeshPrivate::planeW
QVector3D planeW
Definition
qwavefrontmesh.cpp:48
QWavefrontMeshPrivate::source
QUrl source
Definition
qwavefrontmesh.cpp:44
QWavefrontMeshPrivate::planeV
QVector3D planeV
Definition
qwavefrontmesh.cpp:47
QWavefrontMeshPrivate::get
static QWavefrontMeshPrivate * get(QWavefrontMesh *mesh)
Definition
qwavefrontmesh.cpp:30
QWavefrontMeshPrivate::get
static const QWavefrontMeshPrivate * get(const QWavefrontMesh *mesh)
Definition
qwavefrontmesh.cpp:35
QWavefrontMeshPrivate::textureCoordinates
QList< QVector2D > textureCoordinates
Definition
qwavefrontmesh.cpp:42
QWavefrontMeshPrivate::QWavefrontMeshPrivate
QWavefrontMeshPrivate()
Definition
qwavefrontmesh.cpp:24
QWavefrontMesh
Definition
qwavefrontmesh_p.h:30
QT_BEGIN_NAMESPACE
Combined button and popup list for selecting options.
Definition
qsequentialanimationgroup.cpp:47
qtdeclarative
src
labs
wavefrontmesh
qwavefrontmesh_p.h
Generated on
for Qt by
1.18.0