| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
#ifndef POINTLIGHTBLOCK_H |
| 5 |
#define POINTLIGHTBLOCK_H |
| 6 |
|
| 7 |
#include <Qt3DRender/QAbstractLight> |
| 8 |
#include <Qt3DRender/QShaderData> |
| 9 |
|
| 10 |
class PointLightBlock : public Qt3DRender::QShaderData |
| 11 |
{ |
| 12 |
Q_OBJECT |
| 13 |
Q_PROPERTY(QList<Qt3DRender::QAbstractLight *> lights READ lights NOTIFY lightsChanged) |
| 14 |
public: |
| 15 |
explicit PointLightBlock(Qt3DCore::QNode *parent = 0); |
| 16 |
~PointLightBlock(); |
| 17 |
|
| 18 |
QList<Qt3DRender::QAbstractLight *> lights() const; |
| 19 |
void addLight(Qt3DRender::QAbstractLight *light); |
| 20 |
|
| 21 |
Q_SIGNALS: |
| 22 |
void lightsChanged(); |
| 23 |
|
| 24 |
private: |
| 25 |
QList<Qt3DRender::QAbstractLight *> m_lights; |
| 26 |
}; |
| 27 |
|
| 28 |
#endif |