You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

ugeentitycube.h 897B

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. #ifndef UGEENTITYCUBE_H
  2. #define UGEENTITYCUBE_H
  3. #include "ugeentity.h"
  4. class UGEEntityCube : public UGEEntity
  5. {
  6. Q_OBJECT
  7. public:
  8. explicit UGEEntityCube(QObject *parent = 0);
  9. double getSize() const;
  10. QVariant getTextureId() const;
  11. virtual void onDraw(AbstractRenderDevice* device);
  12. void onUpdate();
  13. virtual Vector3D getVectorNearestIntesection(const Vector3D &vector, const Vector3D &origin, bool* ok);
  14. signals:
  15. void sizeChanged();
  16. void sizeChanged(double);
  17. void textureChanged();
  18. void textureChanged(const QVariant& textureId);
  19. public slots:
  20. void setSize(double size);
  21. void increaseSize(double size);
  22. void setTextureId(const QVariant &textureId);
  23. protected:
  24. double _size;
  25. QVariant _textureId;
  26. QList<QList<TextureVector3D> > _facesTexture;
  27. QList<QList<ColorVector3D> > _facesColor;
  28. };
  29. #endif // UGEENTITYCUBE_H