]> SALOME platform Git repositories - modules/geom.git/blob - src/OBJECT/GEOM_EdgeSource.h
Salome HOME
IMP 0016175: EDF455: Save GUIState don't redisplay the objects.
[modules/geom.git] / src / OBJECT / GEOM_EdgeSource.h
1 #ifndef GEOM_EDGESOURCE_H 
2 #define GEOM_EDGESOURCE_H 
3  
4 #include "GEOM_DeviceActor.h" 
5  
6 #include <TopoDS_Edge.hxx> 
7 #include <NCollection_Set.hxx> 
8  
9 typedef NCollection_Set<TopoDS_Edge> TEdgeSet; 
10  
11 #include <vtkPolyDataSource.h> 
12  
13  
14 class VTK_EXPORT GEOM_EdgeSource: public vtkPolyDataSource 
15
16 public: 
17   vtkTypeMacro(GEOM_EdgeSource,vtkPolyDataSource); 
18   static GEOM_EdgeSource* New(); 
19  
20   void AddEdge (const TopoDS_Edge& theEdge,
21                 bool theIsVector = false);
22   void Clear(){ myEdgeSet.Clear();} 
23  
24   static  
25   void OCC2VTK(const TopoDS_Edge& theEdge,  
26                vtkPolyData* thePolyData, 
27                vtkPoints* thePts,
28                bool theIsVector = false); 
29  
30 protected: 
31   TEdgeSet myEdgeSet;
32   // The <myIsVector> flag is common for all edges, because the shape,
33   // representing a vector, can have only one edge.
34   bool myIsVector;
35  
36   void Execute(); 
37  
38   GEOM_EdgeSource(); 
39   ~GEOM_EdgeSource(); 
40  
41 private: 
42   // Not implememnted 
43   GEOM_EdgeSource(const GEOM_EdgeSource&); 
44   void operator=(const GEOM_EdgeSource&); 
45 }; 
46  
47  
48 #endif //GEOM_EDGESOURCE_H