11namespace osg {
class Switch; };
16 SceneNodeBase() :
shapeNode(nullptr), treeItemID(0), modelEntityID(0), editable(false), visible(true), selected(false), transparent(false),
17 wireframe(false), highlighted(false), offset(1.0), selectChildren(true), manageVisibilityOfParent(true), manageVisibilityOfChildren(true), parent(nullptr) {};
26 if (parent !=
nullptr)
30 std::list<SceneNodeBase*> currentChilds = children;
31 for (
auto child : currentChilds)
37 void setName(
const std::string &n) { name = n; };
38 const std::string&
getName(
void) {
return name; };
56 virtual void setSelected(
bool _selected,
bool _selectionFromNavigationTree)
70 virtual void setHighlighted(
bool h) {
if (highlighted !=
h) { highlighted =
h;
if (selectChildren) {
for (
auto child : children) child->setHighlighted(
h); } } };
91 void addChild(
SceneNodeBase *child) { assert(std::find(children.begin(), children.end(), child) == children.end()); children.push_back(child); child->
setParent(
this); };
92 void removeChild(
SceneNodeBase *child) { assert(std::find(children.begin(), children.end(), child) != children.end()); children.remove(child); };
93 const std::list<SceneNodeBase*> &
getChildren(
void) {
return children; };
98 virtual void getPrefetch(std::string &projectName, std::list<std::pair<unsigned long long, unsigned long long>> &prefetchIDs) {};
113 unsigned long long modelEntityID;
117 bool m_selectionFromNavigationTree;
123 bool manageVisibilityOfParent;
124 bool manageVisibilityOfChildren;
127 std::list<SceneNodeBase*> children;
128 OldTreeIcon treeIcons;
130 std::list<Visualiser*> m_visualiser;
bsoncxx::types::value value
Definition DocumentManager.h:16
@ e
Definition SourceTarget.h:4
@ h
Definition SourceTarget.h:4
Definition SceneNodeBase.h:14
bool isEditable(void)
Definition SceneNodeBase.h:49
osg::Switch * shapeNode
Definition SceneNodeBase.h:107
virtual void setHighlighted(bool h)
Definition SceneNodeBase.h:70
SceneNodeBase * getParent(void)
Definition SceneNodeBase.h:89
virtual bool isItem1D(void)=0
void setModelEntityID(unsigned long long id)
Definition SceneNodeBase.h:46
double getOffset(void)
Definition SceneNodeBase.h:77
void setSelectChildren(bool flag)
Definition SceneNodeBase.h:79
bool getManageVisibilityOfParent(void)
Definition SceneNodeBase.h:83
std::string getErrors(void)
Definition SceneNodeBase.h:74
virtual bool getSelectChildren(void)
Definition SceneNodeBase.h:80
void setTreeItemID(ot::UID iD)
Definition SceneNodeBase.h:43
virtual ~SceneNodeBase()
Definition SceneNodeBase.h:18
virtual void setSelected(bool _selected, bool _selectionFromNavigationTree)
Definition SceneNodeBase.h:56
void setParent(SceneNodeBase *item)
Definition SceneNodeBase.h:88
virtual void setTransparent(bool t)
Definition SceneNodeBase.h:64
bool getManageVisibilityOfChildren(void)
Definition SceneNodeBase.h:86
void setShapeNode(osg::Switch *node)
Definition SceneNodeBase.h:40
bool hasErrors(void)
Definition SceneNodeBase.h:73
void setName(const std::string &n)
Definition SceneNodeBase.h:37
void addVisualiser(Visualiser *_visualiser)
Definition SceneNodeBase.h:103
void removeChild(SceneNodeBase *child)
Definition SceneNodeBase.h:92
const std::list< Visualiser * > & getVisualiser()
Definition SceneNodeBase.h:104
bool isHighlighted(void)
Definition SceneNodeBase.h:69
void setOldTreeIcons(const OldTreeIcon &icons)
Definition SceneNodeBase.h:95
const std::list< SceneNodeBase * > & getChildren(void)
Definition SceneNodeBase.h:93
bool isWireframe(void)
Definition SceneNodeBase.h:66
virtual void setVisible(bool v)
Definition SceneNodeBase.h:53
const std::string & getName(void)
Definition SceneNodeBase.h:38
void setManageVisibilityOfParent(bool flag)
Definition SceneNodeBase.h:82
unsigned long long getModelEntityID(void)
Definition SceneNodeBase.h:47
void setErrors(std::string &e)
Definition SceneNodeBase.h:72
ot::UID getTreeItemID(void)
Definition SceneNodeBase.h:44
SceneNodeBase()
Definition SceneNodeBase.h:16
void setManageVisibilityOfChildren(bool flag)
Definition SceneNodeBase.h:85
osg::Switch * getShapeNode(void)
Definition SceneNodeBase.h:41
const float transparency
Definition SceneNodeBase.h:108
bool isSelected(void)
Definition SceneNodeBase.h:55
virtual bool isItem3D(void)=0
void addChild(SceneNodeBase *child)
Definition SceneNodeBase.h:91
const OldTreeIcon & getOldTreeIcons(void)
Definition SceneNodeBase.h:96
virtual void setEditable(bool v)
Definition SceneNodeBase.h:50
bool isTransparent(void)
Definition SceneNodeBase.h:63
virtual void setWireframe(bool w)
Definition SceneNodeBase.h:67
virtual void getPrefetch(std::string &projectName, std::list< std::pair< unsigned long long, unsigned long long > > &prefetchIDs)
Definition SceneNodeBase.h:98
bool isVisible(void)
Definition SceneNodeBase.h:52
void setOffset(double value)
Definition SceneNodeBase.h:76
Definition Visualiser.h:8
Definition RubberbandOsgWrapper.h:22
unsigned long UID
Unique identifier (32 bit unsigned integer)
Definition CoreTypes.h:27