Flow Visualisation
ISceneGraphPart.h
Go to the documentation of this file.
1 //
2 // ISceneGraphPart.h
3 // flowviz
4 //
5 // Created by Johann Götz on 01.05.15.
6 // Copyright (c) 2015 Johann Götz. All rights reserved.
7 //
8 
9 #ifndef __flowviz__ISceneGraphPart__
10 #define __flowviz__ISceneGraphPart__
11 
12 #include <stdio.h>
13 #include <vector>
14 
15 
16 
17 namespace render {
18  class SceneContext;
19 
24  {
25  protected:
27  std::vector<ISceneGraphPart*> m_children;
29  public:
30  ISceneGraphPart() : m_parent(NULL) {}
31 
35  void addChild(ISceneGraphPart *child);
36 
40  void removeChild(ISceneGraphPart *child);
41 
46  virtual void render(SceneContext *context) = 0;
47 
48  virtual ~ISceneGraphPart() {}
49  };
50 }
51 
52 #endif /* defined(__flowviz__ISceneGraphPart__) */
virtual ~ISceneGraphPart()
Definition: ISceneGraphPart.h:48
ISceneGraphPart * m_parent
Definition: ISceneGraphPart.h:26
std::vector< ISceneGraphPart * > m_children
parent element in the scene graph
Definition: ISceneGraphPart.h:27
ISceneGraphPart()
child elements in the scene graph
Definition: ISceneGraphPart.h:30
Represents the current state of rendering.
Definition: SceneContext.h:22
void addChild(ISceneGraphPart *child)
adds child to this element in the scenegraph
Definition: ISceneGraphPart.cpp:13
Represents part of the SceneGraph.
Definition: ISceneGraphPart.h:23
Definition: Camera.h:19
virtual void render(SceneContext *context)=0
renders the current elment and all children in the SceneGraph
void removeChild(ISceneGraphPart *child)
removes child from the scenegraph
Definition: ISceneGraphPart.cpp:19