Point Cloud Library (PCL)  1.7.0
object.h
1 #ifndef PCL_OUTOFCORE_OBJECT_H_
2 #define PCL_OUTOFCORE_OBJECT_H_
3 
4 // C++
5 #include <map>
6 #include <set>
7 #include <string>
8 
9 // VTK
10 #include <vtkActor.h>
11 #include <vtkActorCollection.h>
12 #include <vtkRenderer.h>
13 #include <vtkSmartPointer.h>
14 
15 // Boost
16 //#include <boost/date_time.hpp>
17 //#include <boost/filesystem.hpp>
18 #include <boost/thread.hpp>
19 
20 //Forward Declaration
21 class Scene;
22 
23 class Object
24 {
25 public:
26 
27  // Operators
28  // -----------------------------------------------------------------------------
29  Object (std::string name);
30 
31  virtual
32  ~Object () { }
33 
34 
35  // Accessors
36  // -----------------------------------------------------------------------------
37  std::string
38  getName () const;
39 
40  void
41  setName (std::string name);
42 
43  virtual void
44  render (vtkRenderer* renderer);
45 
46  bool
47  hasActor (vtkActor *actor);
48 
49  void
50  addActor (vtkActor *actor);
51 
52  void
53  removeActor (vtkActor *actor);
54 
56  getActors ();
57 
58 protected:
60  boost::mutex actors_mutex_;
61 
62 private:
63 
64  // Members
65  // -----------------------------------------------------------------------------
66  std::string name_;
67  std::map<vtkActor*, std::set<vtkRenderer*> > associated_renderers_;
68 
69 };
70 
71 #endif