1 | // Copyright (C) 2015 Klaralvdalens Datakonsult AB (KDAB). |
2 | // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only |
3 | #ifndef QT3DRENDER_QPOINTSIZE_H |
4 | #define QT3DRENDER_QPOINTSIZE_H |
5 | |
6 | #include <Qt3DRender/qrenderstate.h> |
7 | |
8 | QT_BEGIN_NAMESPACE |
9 | |
10 | namespace Qt3DRender { |
11 | |
12 | class QPointSizePrivate; |
13 | |
14 | class Q_3DRENDERSHARED_EXPORT QPointSize : public QRenderState |
15 | { |
16 | Q_OBJECT |
17 | Q_PROPERTY(SizeMode sizeMode READ sizeMode WRITE setSizeMode NOTIFY sizeModeChanged) |
18 | Q_PROPERTY(float value READ value WRITE setValue NOTIFY valueChanged) |
19 | |
20 | public: |
21 | enum SizeMode { |
22 | Fixed = 0, |
23 | Programmable = 1 |
24 | }; |
25 | Q_ENUM(SizeMode) // LCOV_EXCL_LINE |
26 | |
27 | explicit QPointSize(Qt3DCore::QNode *parent = nullptr); |
28 | ~QPointSize(); |
29 | |
30 | SizeMode sizeMode() const; |
31 | float value() const; |
32 | |
33 | public Q_SLOTS: |
34 | void setSizeMode(SizeMode sizeMode); |
35 | void setValue(float value); |
36 | |
37 | Q_SIGNALS: |
38 | void sizeModeChanged(SizeMode sizeMode); |
39 | void valueChanged(float value); |
40 | |
41 | private: |
42 | Q_DECLARE_PRIVATE(QPointSize) |
43 | }; |
44 | |
45 | } // namespace Qt3DRender |
46 | |
47 | QT_END_NAMESPACE |
48 | |
49 | #endif // QT3DRENDER_QPOINTSIZE_H |
50 | |