b311480e |
1 | -- Created on: 1993-09-28 |
2 | -- Created by: Bruno DUMORTIER |
3 | -- Copyright (c) 1993-1999 Matra Datavision |
973c2be1 |
4 | -- Copyright (c) 1999-2014 OPEN CASCADE SAS |
b311480e |
5 | -- |
973c2be1 |
6 | -- This file is part of Open CASCADE Technology software library. |
b311480e |
7 | -- |
d5f74e42 |
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 |
973c2be1 |
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. |
b311480e |
13 | -- |
973c2be1 |
14 | -- Alternatively, this file may be used under the terms of Open CASCADE |
15 | -- commercial license or contractual agreement. |
b311480e |
16 | |
17 | ---Purpose: Tools and Data to filling Surface and Sweep Surfaces |
7fd59977 |
18 | |
19 | package GeomFill |
20 | |
21 | uses |
22 | TColgp, |
23 | TColGeom, |
24 | TColGeom2d, |
25 | TColStd, |
26 | TCollection, |
27 | gp, |
28 | Geom, |
29 | Geom2d, |
30 | GeomAbs, |
31 | Convert, |
32 | Adaptor3d, |
33 | GeomAdaptor, |
34 | Law, |
35 | Extrema, |
36 | AppBlend, |
37 | Approx, |
38 | math, |
39 | MMgt, |
40 | StdFail |
41 | |
42 | is |
43 | |
44 | enumeration FillingStyle |
45 | is StretchStyle, CoonsStyle, CurvedStyle end; |
46 | ---Purpose: Defines the three filling styles used in this package |
47 | -- - GeomFill_Stretch - the style with the flattest patches |
48 | -- - GeomFill_Coons - a rounded style of patch with |
49 | -- less depth than those of Curved |
50 | -- - GeomFill_Curved - the style with the most rounded patches. |
51 | enumeration ApproxStyle |
52 | is Section, Location end; |
53 | |
54 | enumeration PipeError |
55 | is PipeOk, |
56 | PipeNotOk, |
57 | PlaneNotIntersectGuide, |
58 | ImpossibleContact |
59 | end; |
60 | |
61 | |
62 | enumeration Trihedron |
63 | is IsCorrectedFrenet, IsFixed, IsFrenet, IsConstantNormal, IsDarboux, |
64 | IsGuideAC, IsGuidePlan, |
a31abc03 |
65 | IsGuideACWithContact, IsGuidePlanWithContact, IsDiscreteTrihedron end; |
7fd59977 |
66 | |
67 | class Filling; |
7fd59977 |
68 | |
69 | class Stretch; |
70 | |
71 | class Coons; |
72 | |
73 | class Curved; |
74 | |
75 | |
76 | class BezierCurves; |
ff8178ef |
77 | |
7fd59977 |
78 | class BSplineCurves; |
ff8178ef |
79 | |
7fd59977 |
80 | class Profiler; |
ff8178ef |
81 | |
7fd59977 |
82 | class SectionGenerator; |
7fd59977 |
83 | |
84 | class Line; |
ff8178ef |
85 | |
7fd59977 |
86 | class AppSurf instantiates AppSurf from AppBlend |
87 | ( SectionGenerator from GeomFill, |
88 | Line from GeomFill); |
89 | ---Purpose: Approximate a BSplineSurface passing by all the |
90 | -- curves described in the SectionGenerator |
91 | |
92 | |
93 | class SweepSectionGenerator; |
7fd59977 |
94 | |
95 | class AppSweep instantiates AppSurf from AppBlend |
96 | ( SweepSectionGenerator from GeomFill, |
97 | Line from GeomFill); |
98 | ---Purpose: Approximate a sweep surface passing by all the |
99 | -- curves described in the SweepSectionGenerator. |
100 | |
101 | |
102 | class Generator; |
7fd59977 |
103 | |
104 | class Pipe; |
7fd59977 |
105 | |
106 | |
107 | --- Family of classes providing algorithms to fill a contour with |
108 | -- constraints of tangency. |
109 | |
ff8178ef |
110 | |
7fd59977 |
111 | class Tensor; |
112 | |
113 | |
114 | class ConstrainedFilling; |
7fd59977 |
115 | |
116 | deferred class Boundary; -- inherits TShared |
ff8178ef |
117 | |
7fd59977 |
118 | class DegeneratedBound; -- inherits Boundary |
ff8178ef |
119 | |
7fd59977 |
120 | class SimpleBound; -- inherits Boundary |
ff8178ef |
121 | |
7fd59977 |
122 | class BoundWithSurf; -- inherits Boundary |
7fd59977 |
123 | |
124 | class CoonsAlgPatch; -- inherits TShared |
7fd59977 |
125 | |
126 | deferred class TgtField; -- inherits TShared |
7fd59977 |
127 | |
128 | class TgtOnCoons; -- inherits TgteField |
7fd59977 |
129 | |
130 | class CornerState; |
7fd59977 |
131 | |
132 | -- |
133 | -- instantiation of Sequence of Trsf |
134 | -- |
135 | |
136 | class SequenceOfTrsf |
137 | instantiates Sequence from TCollection (Trsf from gp); |
138 | |
a31abc03 |
139 | class SequenceOfAx2 |
140 | instantiates Sequence from TCollection (Ax2 from gp); |
141 | |
142 | class HSequenceOfAx2 |
143 | instantiates HSequence from TCollection (Ax2 from gp, |
144 | SequenceOfAx2 from GeomFill); |
145 | |
7fd59977 |
146 | -- |
147 | -- private classes |
148 | -- |
149 | |
150 | private class CircularBlendFunc; |
151 | private class SweepFunction; |
152 | private class LocFunction; |
153 | private class PolynomialConvertor; |
154 | private class QuasiAngularConvertor; |
155 | private class SnglrFunc; |
156 | private class FunctionDraft; |
157 | private class PlanFunc; |
158 | private class FunctionGuide; |
159 | |
160 | --- |
161 | --- Sweep Data |
162 | --- |
163 | deferred class SectionLaw; |
164 | class UniformSection; |
165 | class EvolvedSection; |
166 | class NSections; |
167 | |
168 | deferred class LocationLaw; |
169 | class CurveAndTrihedron; |
170 | class LocationDraft; |
171 | class LocationGuide; |
172 | |
173 | deferred class TrihedronLaw; |
174 | class Fixed; |
175 | class Frenet; |
176 | class CorrectedFrenet; |
a31abc03 |
177 | class DiscreteTrihedron; |
7fd59977 |
178 | class ConstantBiNormal; |
179 | class Darboux; |
180 | class DraftTrihedron; |
181 | |
182 | |
183 | deferred class TrihedronWithGuide; |
184 | class GuideTrihedronAC; |
185 | class GuideTrihedronPlan; |
186 | |
187 | |
188 | |
189 | class Sweep; |
190 | class SectionPlacement; |
191 | |
192 | class Array1OfSectionLaw |
193 | instantiates Array1 from TCollection (SectionLaw from GeomFill); |
194 | |
195 | class HArray1OfSectionLaw |
196 | instantiates HArray1 from TCollection (SectionLaw from GeomFill, |
197 | Array1OfSectionLaw from GeomFill); |
198 | |
199 | class Array1OfLocationLaw |
200 | instantiates Array1 from TCollection (LocationLaw from GeomFill); |
201 | |
202 | class HArray1OfLocationLaw |
203 | instantiates HArray1 from TCollection (LocationLaw from GeomFill, |
204 | Array1OfLocationLaw from GeomFill); |
205 | |
206 | -- package methods |
207 | -- |
208 | |
209 | Surface( Curve1 : Curve from Geom; |
210 | Curve2 : Curve from Geom) |
211 | returns Surface from Geom; |
212 | ---Purpose: |
213 | -- Builds a ruled surface between the two curves, Curve1 and Curve2. |
214 | GetCircle(TConv : ParameterisationType from Convert; |
215 | ns1, ns2 : Vec from gp; |
216 | nplan : Vec from gp; |
217 | pt1, pt2 : Pnt from gp; |
218 | Rayon : Real from Standard; |
219 | Center : Pnt from gp; |
220 | Poles : out Array1OfPnt from TColgp; |
221 | Weigths : out Array1OfReal from TColStd); |
222 | |
223 | GetCircle(TConv : ParameterisationType from Convert; |
224 | ns1, ns2 : Vec from gp; |
225 | dn1w, dn2w : Vec from gp; |
226 | nplan, dnplan : Vec from gp; |
227 | pts1, pts2 : Pnt from gp; |
228 | tang1, tang2 : Vec from gp; |
229 | Rayon, DRayon : Real from Standard; |
230 | Center : Pnt from gp; |
231 | DCenter : Vec from gp; |
232 | Poles : out Array1OfPnt from TColgp; |
233 | DPoles : out Array1OfVec from TColgp; |
234 | Weigths : out Array1OfReal from TColStd; |
235 | DWeigths : out Array1OfReal from TColStd) |
236 | ---Level: Internal |
237 | returns Boolean; |
238 | |
239 | GetCircle(TConv : ParameterisationType from Convert; |
240 | ns1, ns2 : Vec from gp; |
241 | dn1w, dn2w : Vec from gp; |
242 | d2n1w, d2n2w : Vec from gp; |
243 | nplan, dnplan, d2nplan : Vec from gp; |
244 | pts1 , pts2 : Pnt from gp; |
245 | tang1 , tang2 : Vec from gp; |
246 | Dtang1, Dtang2 : Vec from gp; |
247 | Rayon, DRayon, D2Rayon : Real from Standard; |
248 | Center : Pnt from gp; |
249 | DCenter, D2Center : Vec from gp; |
250 | Poles : out Array1OfPnt from TColgp; |
251 | DPoles : out Array1OfVec from TColgp; |
252 | D2Poles : out Array1OfVec from TColgp; |
253 | Weigths : out Array1OfReal from TColStd; |
254 | DWeigths : out Array1OfReal from TColStd; |
255 | D2Weigths : out Array1OfReal from TColStd) |
256 | ---Level: Internal |
257 | returns Boolean; |
258 | |
259 | GetShape(MaxAng: Real from Standard; |
260 | NbPoles,NbKnots,Degree : out Integer from Standard; |
261 | TypeConv : in out ParameterisationType from Convert); |
262 | |
263 | Knots(TypeConv : ParameterisationType from Convert; |
264 | TKnots: out Array1OfReal from TColStd); |
265 | |
266 | |
267 | Mults(TypeConv : ParameterisationType from Convert; |
268 | TMults: out Array1OfInteger from TColStd); |
269 | |
270 | GetMinimalWeights(TConv : ParameterisationType from Convert; |
271 | AngleMin : Real; |
272 | AngleMax : Real; |
273 | Weigths : out Array1OfReal from TColStd); |
274 | |
275 | GetTolerance(TConv : ParameterisationType from Convert; |
276 | AngleMin : Real; |
277 | Radius : Real; |
278 | AngularTol : Real; |
279 | SpatialTol : Real) |
280 | ---Purpose: Used by the generical classes to determine |
281 | -- Tolerance for approximation |
282 | ---Level: Internal |
283 | returns Real; |
284 | |
285 | end GeomFill; |