0030480: Visualization - Clear of Select3D_SensitiveGroup does not update internal...
[occt.git] / src / HLRTopoBRep / HLRTopoBRep_Data.hxx
CommitLineData
42cf5bc1 1// Created on: 1994-10-24
2// Created by: Christophe MARION
3// Copyright (c) 1994-1999 Matra Datavision
4// Copyright (c) 1999-2014 OPEN CASCADE SAS
5//
6// This file is part of Open CASCADE Technology software library.
7//
8// This library is free software; you can redistribute it and/or modify it under
9// the terms of the GNU Lesser General Public License version 2.1 as published
10// by the Free Software Foundation, with special exception defined in the file
11// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12// distribution for complete text of the license and disclaimer of any warranty.
13//
14// Alternatively, this file may be used under the terms of Open CASCADE
15// commercial license or contractual agreement.
16
17#ifndef _HLRTopoBRep_Data_HeaderFile
18#define _HLRTopoBRep_Data_HeaderFile
19
20#include <Standard.hxx>
21#include <Standard_DefineAlloc.hxx>
22#include <Standard_Handle.hxx>
23
24#include <TopTools_DataMapOfShapeShape.hxx>
25#include <TopTools_DataMapOfShapeListOfShape.hxx>
26#include <HLRTopoBRep_DataMapOfShapeFaceData.hxx>
27#include <TopTools_MapOfShape.hxx>
28#include <HLRTopoBRep_MapOfShapeListOfVData.hxx>
29#include <HLRTopoBRep_DataMapIteratorOfMapOfShapeListOfVData.hxx>
30#include <HLRTopoBRep_ListIteratorOfListOfVData.hxx>
42cf5bc1 31#include <Standard_Boolean.hxx>
32#include <TopTools_ListOfShape.hxx>
33#include <Standard_Real.hxx>
34class TopoDS_Edge;
35class TopoDS_Face;
36class TopoDS_Shape;
37class TopoDS_Vertex;
38
39
40//! Stores the results of the OutLine and IsoLine
41//! processes.
42class HLRTopoBRep_Data
43{
44public:
45
46 DEFINE_STANDARD_ALLOC
47
48
49 Standard_EXPORT HLRTopoBRep_Data();
50
51 //! Clear of all the maps.
52 Standard_EXPORT void Clear();
53
54 //! Clear of all the data not needed during and after
55 //! the hiding process.
56 Standard_EXPORT void Clean();
57
58 //! Returns True if the Edge is split.
59 Standard_EXPORT Standard_Boolean EdgeHasSplE (const TopoDS_Edge& E) const;
60
61 //! Returns True if the Face has internal outline.
62 Standard_EXPORT Standard_Boolean FaceHasIntL (const TopoDS_Face& F) const;
63
64 //! Returns True if the Face has outlines on restriction.
65 Standard_EXPORT Standard_Boolean FaceHasOutL (const TopoDS_Face& F) const;
66
67 //! Returns True if the Face has isolines.
68 Standard_EXPORT Standard_Boolean FaceHasIsoL (const TopoDS_Face& F) const;
69
70 Standard_EXPORT Standard_Boolean IsSplEEdgeEdge (const TopoDS_Edge& E1, const TopoDS_Edge& E2) const;
71
72 Standard_EXPORT Standard_Boolean IsIntLFaceEdge (const TopoDS_Face& F, const TopoDS_Edge& E) const;
73
74 Standard_EXPORT Standard_Boolean IsOutLFaceEdge (const TopoDS_Face& F, const TopoDS_Edge& E) const;
75
76 Standard_EXPORT Standard_Boolean IsIsoLFaceEdge (const TopoDS_Face& F, const TopoDS_Edge& E) const;
77
78 Standard_EXPORT TopoDS_Shape NewSOldS (const TopoDS_Shape& New) const;
79
80 //! Returns the list of the edges.
81 const TopTools_ListOfShape& EdgeSplE (const TopoDS_Edge& E) const;
82
83 //! Returns the list of the internal OutLines.
84 const TopTools_ListOfShape& FaceIntL (const TopoDS_Face& F) const;
85
86 //! Returns the list of the OutLines on restriction.
87 const TopTools_ListOfShape& FaceOutL (const TopoDS_Face& F) const;
88
89 //! Returns the list of the IsoLines.
90 const TopTools_ListOfShape& FaceIsoL (const TopoDS_Face& F) const;
91
92 //! Returns True if V is an outline vertex on a
93 //! restriction.
94 Standard_Boolean IsOutV (const TopoDS_Vertex& V) const;
95
96 //! Returns True if V is an internal outline vertex.
97 Standard_Boolean IsIntV (const TopoDS_Vertex& V) const;
98
99 Standard_EXPORT void AddOldS (const TopoDS_Shape& NewS, const TopoDS_Shape& OldS);
100
101 Standard_EXPORT TopTools_ListOfShape& AddSplE (const TopoDS_Edge& E);
102
103 Standard_EXPORT TopTools_ListOfShape& AddIntL (const TopoDS_Face& F);
104
105 Standard_EXPORT TopTools_ListOfShape& AddOutL (const TopoDS_Face& F);
106
107 Standard_EXPORT TopTools_ListOfShape& AddIsoL (const TopoDS_Face& F);
108
109 void AddOutV (const TopoDS_Vertex& V);
110
111 void AddIntV (const TopoDS_Vertex& V);
112
113 Standard_EXPORT void InitEdge();
114
115 Standard_Boolean MoreEdge() const;
116
117 Standard_EXPORT void NextEdge();
118
119 const TopoDS_Edge& Edge() const;
120
121 //! Start an iteration on the vertices of E.
122 Standard_EXPORT void InitVertex (const TopoDS_Edge& E);
123
124 Standard_Boolean MoreVertex() const;
125
126 void NextVertex();
127
128 Standard_EXPORT const TopoDS_Vertex& Vertex() const;
129
130 Standard_EXPORT Standard_Real Parameter() const;
131
132 //! Insert before the current position.
133 Standard_EXPORT void InsertBefore (const TopoDS_Vertex& V, const Standard_Real P);
134
135 Standard_EXPORT void Append (const TopoDS_Vertex& V, const Standard_Real P);
136
137
138
139
140protected:
141
142
143
144
145
146private:
147
148
149
150 TopTools_DataMapOfShapeShape myOldS;
151 TopTools_DataMapOfShapeListOfShape mySplE;
152 HLRTopoBRep_DataMapOfShapeFaceData myData;
153 TopTools_MapOfShape myOutV;
154 TopTools_MapOfShape myIntV;
155 HLRTopoBRep_MapOfShapeListOfVData myEdgesVertices;
156 HLRTopoBRep_DataMapIteratorOfMapOfShapeListOfVData myEIterator;
157 HLRTopoBRep_ListIteratorOfListOfVData myVIterator;
681f3919 158 HLRTopoBRep_ListOfVData* myVList;
42cf5bc1 159
160
161};
162
163
164#include <HLRTopoBRep_Data.lxx>
165
166
167
168
169
170#endif // _HLRTopoBRep_Data_HeaderFile