Tulip  5.3.0
Large graphs analysis and drawing
GlSceneVisitor.h
1 /*
2  *
3  * This file is part of Tulip (http://tulip.labri.fr)
4  *
5  * Authors: David Auber and the Tulip development Team
6  * from LaBRI, University of Bordeaux
7  *
8  * Tulip is free software; you can redistribute it and/or modify
9  * it under the terms of the GNU Lesser General Public License
10  * as published by the Free Software Foundation, either version 3
11  * of the License, or (at your option) any later version.
12  *
13  * Tulip is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
16  * See the GNU General Public License for more details.
17  *
18  */
19 ///@cond DOXYGEN_HIDDEN
20 
21 #ifndef Tulip_GLSCENEVISITOR_H
22 #define Tulip_GLSCENEVISITOR_H
23 
24 #include <tulip/tulipconf.h>
25 
26 namespace tlp {
27 
28 class GlSimpleEntity;
29 class GlNode;
30 class GlEdge;
31 class GlLayer;
32 
33 class TLP_GL_SCOPE GlSceneVisitor {
34 
35 public:
36  GlSceneVisitor() : threadSafe(false) {}
37  virtual ~GlSceneVisitor() {}
38 
39  virtual void visit(GlSimpleEntity *) {}
40  virtual void visit(GlNode *) {}
41  virtual void visit(GlEdge *) {}
42  virtual void visit(GlLayer *) {}
43  virtual void endOfVisit() {}
44  virtual void reserveMemoryForGraphElts(unsigned int /*nbNodes*/, unsigned int /*nbEdges*/) {}
45 
46  bool isThreadSafe() {
47  return threadSafe;
48  }
49 
50 protected:
51  bool threadSafe;
52 };
53 } // namespace tlp
54 
55 #endif // Tulip_GLSCENEVISITOR_H
56 ///@endcond