MNE-CPP 0.1.9
A Framework for Electrophysiology
Loading...
Searching...
No Matches
abstract3Dtreeitem.h
Go to the documentation of this file.
1//=============================================================================================================
36#ifndef DISP3DLIB_ABSTRACT3DTREEITEM_H
37#define DISP3DLIB_ABSTRACT3DTREEITEM_H
38
39//=============================================================================================================
40// INCLUDES
41//=============================================================================================================
42
43#include "../../../../disp3D_global.h"
44#include "../../3dhelpers/renderable3Dentity.h"
45#include "types.h"
46
47//=============================================================================================================
48// QT INCLUDES
49//=============================================================================================================
50
51#include <QStandardItem>
52
53//=============================================================================================================
54// EIGEN INCLUDES
55//=============================================================================================================
56
57//=============================================================================================================
58// FORWARD DECLARATIONS
59//=============================================================================================================
60
61//=============================================================================================================
62// DEFINE NAMESPACE DISP3DLIB
63//=============================================================================================================
64
65namespace DISP3DLIB
66{
67
68//=============================================================================================================
69// DISP3DLIB FORWARD DECLARATIONS
70//=============================================================================================================
71
72class MetaTreeItem;
73
74//=============================================================================================================
80class DISP3DSHARED_EXPORT Abstract3DTreeItem : public Renderable3DEntity, public QStandardItem
81{
82 Q_OBJECT
83
84public :
85 //=========================================================================================================
93 Abstract3DTreeItem(QEntity* p3DEntityParent = 0,
94 int iType = Data3DTreeModelItemTypes::UnknownItem,
95 const QString& text = "");
96
97 //=========================================================================================================
101 void setData(const QVariant& value, int role = Qt::UserRole + 1);
102 int type() const;
103
104 //=========================================================================================================
112 QList<QStandardItem*> findChildren(int type);
113
114 //=========================================================================================================
122 QList<QStandardItem*> findChildren(const QString& text);
123
124 //=========================================================================================================
130 Abstract3DTreeItem &operator<<(Abstract3DTreeItem* newItem);
131
132 //=========================================================================================================
138 Abstract3DTreeItem &operator<<(Abstract3DTreeItem& newItem);
139
140 //=========================================================================================================
149 static Eigen::MatrixX4f createVertColor(int numVert, const QColor& color = QColor(0,49,69));
150
151 //=========================================================================================================
157 void setAlpha(float fAlpha);
158
159protected:
160 //=========================================================================================================
164 virtual void initItem();
165
166 //=========================================================================================================
172 virtual void onCheckStateChanged(const Qt::CheckState& checkState);
173
174 //=========================================================================================================
180 virtual void onTranslationXChanged(const QVariant& fTransX);
181
182 //=========================================================================================================
188 virtual void onTranslationYChanged(const QVariant& fTransY);
189
190 //=========================================================================================================
196 virtual void onTranslationZChanged(const QVariant& fTransZ);
197
198 //=========================================================================================================
204 virtual void onScaleChanged(const QVariant& fScale);
205
206 //=========================================================================================================
212 virtual void onColorChanged(const QVariant& color);
213
214 //=========================================================================================================
220 virtual void onAlphaChanged(const QVariant& fAlpha);
221
224 QPointer<MetaTreeItem> m_pItemTransformationOptions;
225 QPointer<MetaTreeItem> m_pItemAppearanceOptions;
227signals:
228 //=========================================================================================================
234 void checkStateChanged(const Qt::CheckState& checkState);
235};
236} //NAMESPACE DISP3DLIB
237
238#endif // DISP3DLIB_ABSTRACT3DTREEITEM_H
#define DISP3DSHARED_EXPORT
Contains general application specific types.
Base class for renederable 3D QEntities.
Provides the basic tree item.
QPointer< MetaTreeItem > m_pItemTransformationOptions
void checkStateChanged(const Qt::CheckState &checkState)
QPointer< MetaTreeItem > m_pItemAppearanceOptions