v2.0.0
Loading...
Searching...
No Matches
sensortreeitem.h
Go to the documentation of this file.
1//=============================================================================================================
19
20#ifndef SENSORTREEITEM_H
21#define SENSORTREEITEM_H
22
23//=============================================================================================================
24// INCLUDES
25//=============================================================================================================
26
27#include "../../disp3D_global.h"
28
29#include "abstracttreeitem.h"
30#include <QVector3D>
31#include <QMatrix4x4>
32
37{
38public:
39 explicit SensorTreeItem(const QString& text, const QVector3D& pos, const QColor& color, float scale, int type = AbstractTreeItem::SensorItem);
40 ~SensorTreeItem() = default;
41
42 QVector3D position() const;
43 float scale() const;
44
45 //=========================================================================================================
49 void setOrientation(const QMatrix4x4 &orient);
50
51 //=========================================================================================================
55 const QMatrix4x4& orientation() const;
56
57 //=========================================================================================================
61 bool hasOrientation() const;
62
63private:
64 QVector3D m_pos;
65 float m_scale;
66 QMatrix4x4 m_orientation;
67 bool m_hasOrientation = false;
68};
69
70#endif // SENSORTREEITEM_H
Base QStandardItem with check-state, visibility, transform, colour and alpha roles shared by every di...
Library export/import macros and namespace marker for the disp3D library.
#define DISP3DSHARED_EXPORT
QColor color() const
AbstractTreeItem(const QString &text="", int type=AbstractItem)
int type() const override
SensorTreeItem(const QString &text, const QVector3D &pos, const QColor &color, float scale, int type=AbstractTreeItem::SensorItem)
bool hasOrientation() const
~SensorTreeItem()=default
QVector3D position() const
void setOrientation(const QMatrix4x4 &orient)
float scale() const
const QMatrix4x4 & orientation() const