1// Copyright (C) 2014 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
4#ifndef QT3DRENDER_QPOLYGONOFFSET_H
5#define QT3DRENDER_QPOLYGONOFFSET_H
6
7#include <Qt3DRender/qrenderstate.h>
8
9QT_BEGIN_NAMESPACE
10
11namespace Qt3DRender {
12
13class QPolygonOffsetPrivate;
14
15class Q_3DRENDERSHARED_EXPORT QPolygonOffset : public QRenderState
16{
17 Q_OBJECT
18
19 Q_PROPERTY(float scaleFactor READ scaleFactor WRITE setScaleFactor NOTIFY scaleFactorChanged)
20 Q_PROPERTY(float depthSteps READ depthSteps WRITE setDepthSteps NOTIFY depthStepsChanged)
21public:
22 explicit QPolygonOffset(Qt3DCore::QNode *parent = nullptr);
23 ~QPolygonOffset();
24
25 float scaleFactor() const;
26 float depthSteps() const;
27
28public Q_SLOTS:
29 void setScaleFactor(float scaleFactor);
30 void setDepthSteps(float depthSteps);
31
32Q_SIGNALS:
33 void scaleFactorChanged(float scaleFactor);
34 void depthStepsChanged(float depthSteps);
35
36private:
37 Q_DECLARE_PRIVATE(QPolygonOffset)
38};
39
40} // namespace Qt3DRender
41
42QT_END_NAMESPACE
43
44#endif // QT3DRENDER_QPOLYGONOFFSET_H
45

source code of qt3d/src/render/renderstates/qpolygonoffset.h