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 QT3DEXTRAS_QPHONGALPHAMATERIAL_H |
5 | #define |
6 | |
7 | #include <Qt3DExtras/qt3dextras_global.h> |
8 | #include <Qt3DRender/qblendequation.h> |
9 | #include <Qt3DRender/qblendequationarguments.h> |
10 | #include <Qt3DRender/qmaterial.h> |
11 | #include <QtGui/QColor> |
12 | |
13 | QT_BEGIN_NAMESPACE |
14 | |
15 | namespace Qt3DExtras { |
16 | |
17 | class ; |
18 | |
19 | class Q_3DEXTRASSHARED_EXPORT : public Qt3DRender::QMaterial |
20 | { |
21 | Q_OBJECT |
22 | Q_PROPERTY(QColor ambient READ ambient WRITE setAmbient NOTIFY ambientChanged) |
23 | Q_PROPERTY(QColor diffuse READ diffuse WRITE setDiffuse NOTIFY diffuseChanged) |
24 | Q_PROPERTY(QColor specular READ specular WRITE setSpecular NOTIFY specularChanged) |
25 | Q_PROPERTY(float shininess READ shininess WRITE setShininess NOTIFY shininessChanged) |
26 | Q_PROPERTY(float alpha READ alpha WRITE setAlpha NOTIFY alphaChanged) |
27 | Q_PROPERTY(Qt3DRender::QBlendEquationArguments::Blending sourceRgbArg READ sourceRgbArg WRITE setSourceRgbArg NOTIFY sourceRgbArgChanged) |
28 | Q_PROPERTY(Qt3DRender::QBlendEquationArguments::Blending destinationRgbArg READ destinationRgbArg WRITE setDestinationRgbArg NOTIFY destinationRgbArgChanged) |
29 | Q_PROPERTY(Qt3DRender::QBlendEquationArguments::Blending sourceAlphaArg READ sourceAlphaArg WRITE setSourceAlphaArg NOTIFY sourceAlphaArgChanged) |
30 | Q_PROPERTY(Qt3DRender::QBlendEquationArguments::Blending destinationAlphaArg READ destinationAlphaArg WRITE setDestinationAlphaArg NOTIFY destinationAlphaArgChanged) |
31 | Q_PROPERTY(Qt3DRender::QBlendEquation::BlendFunction blendFunctionArg READ blendFunctionArg WRITE setBlendFunctionArg NOTIFY blendFunctionArgChanged) |
32 | |
33 | public: |
34 | explicit (Qt3DCore::QNode *parent = nullptr); |
35 | (); |
36 | |
37 | QColor () const; |
38 | QColor () const; |
39 | QColor () const; |
40 | float () const; |
41 | float () const; |
42 | |
43 | Qt3DRender::QBlendEquationArguments::Blending () const; |
44 | Qt3DRender::QBlendEquationArguments::Blending () const; |
45 | Qt3DRender::QBlendEquationArguments::Blending () const; |
46 | Qt3DRender::QBlendEquationArguments::Blending () const; |
47 | Qt3DRender::QBlendEquation::BlendFunction () const; |
48 | |
49 | public Q_SLOTS: |
50 | void (const QColor &ambient); |
51 | void (const QColor &diffuse); |
52 | void (const QColor &specular); |
53 | void (float shininess); |
54 | void (float alpha); |
55 | void (Qt3DRender::QBlendEquationArguments::Blending sourceRgbArg); |
56 | void (Qt3DRender::QBlendEquationArguments::Blending destinationRgbArg); |
57 | void (Qt3DRender::QBlendEquationArguments::Blending sourceAlphaArg); |
58 | void (Qt3DRender::QBlendEquationArguments::Blending destinationAlphaArg); |
59 | void (Qt3DRender::QBlendEquation::BlendFunction blendFunctionArg); |
60 | |
61 | Q_SIGNALS: |
62 | void (const QColor &ambient); |
63 | void (const QColor &diffuse); |
64 | void (const QColor &specular); |
65 | void (float shininess); |
66 | void (float alpha); |
67 | void (Qt3DRender::QBlendEquationArguments::Blending sourceRgbArg); |
68 | void (Qt3DRender::QBlendEquationArguments::Blending destinationRgbArg); |
69 | void (Qt3DRender::QBlendEquationArguments::Blending sourceAlphaArg); |
70 | void (Qt3DRender::QBlendEquationArguments::Blending destinationAlphaArg); |
71 | void (Qt3DRender::QBlendEquation::BlendFunction blendFunctionArg); |
72 | |
73 | private: |
74 | Q_DECLARE_PRIVATE(QPhongAlphaMaterial) |
75 | }; |
76 | |
77 | } // namespace Qt3DExtras |
78 | |
79 | QT_END_NAMESPACE |
80 | |
81 | #endif // QT3DEXTRAS_QPHONGALPHAMATERIAL_H |
82 | |