1 -- File: BOPTools_PaveFiller.cdl
2 -- Created: Thu Feb 8 14:07:33 2001
3 -- Author: Peter KURNEV
5 ---Copyright: Matra Datavision 2001
8 class PaveFiller from BOPTools
10 ---Purpose: The algorithm that provides
11 --- 1. creation of the data structure (DS)
12 --- 2. creation of the interferences' pool
13 --- 3. invocation of Perform() to fill the DS
18 PShapesDataStructure from BooleanOperations,
20 InterferencePool from BOPTools,
21 PInterferencePool from BOPTools,
22 PavePool from BOPTools,
23 CommonBlockPool from BOPTools,
24 SplitShapesPool from BOPTools,
27 PaveBlock from BOPTools,
28 PaveSet from BOPTools,
30 SSInterference from BOPTools,
31 ListOfPaveBlock from BOPTools,
32 IteratorOfCoupleOfShape from BOPTools,
33 SSInterference from BOPTools,
34 SSIntersectionAttribute from BOPTools,
35 ShrunkRange from IntTools,
36 Context from IntTools,
38 ShapeEnum from TopAbs,
39 ListOfInteger from TColStd,
40 IndexedMapOfInteger from TColStd,
44 SetOfInteger from TColStd
50 returns PaveFiller from BOPTools;
54 Create (aIP: InterferencePool from BOPTools)
55 returns PaveFiller from BOPTools;
59 Create (theIP : InterferencePool from BOPTools;
60 theSectionAttribute: SSIntersectionAttribute from BOPTools)
61 returns PaveFiller from BOPTools;
67 ---C++: alias "Standard_EXPORT virtual ~BOPTools_PaveFiller(){Destroy();}"
77 PartialPerform(me:out; anObjSubSet, aToolSubSet: SetOfInteger from TColStd)
80 ToCompletePerform(me:out)
86 --- Computes Vertex/Vertex interferences
91 --- Computes Vertex/Edge interferences
96 --- Computes Vertex/Face interferences
101 --- Computes Edge/Edge interferences
104 is virtual protected;
106 --- Computes Edge/Face interferences
109 is virtual protected;
111 --- Computes Face/Face interferences
114 --------------------------------------------------------------
120 returns Context from IntTools;
121 ---C++:return const &
125 ChangeContext(me:out)
126 returns Context from IntTools;
131 SetInterferencePool(me:out;
132 aPool:InterferencePool from BOPTools);
137 returns Boolean from Standard;
142 returns PavePool from BOPTools;
143 ---C++:return const &
147 ChangePavePool(me:out)
148 returns PavePool from BOPTools;
154 returns CommonBlockPool from BOPTools;
155 ---C++:return const &
159 ChangeCommonBlockPool(me:out)
160 returns CommonBlockPool from BOPTools;
166 returns SplitShapesPool from BOPTools;
167 ---C++:return const &
172 ChangeSplitShapesPool(me:out)
173 returns SplitShapesPool from BOPTools;
179 returns PShapesDataStructure from BooleanOperations;
184 returns PInterferencePool from BOPTools;
189 IteratorOfCoupleOfShape(me)
190 returns IteratorOfCoupleOfShape from BOPTools;
191 ---C++:return const &
197 returns SSIntersectionAttribute from BOPTools;
198 ---C++: return const &
203 SetSectionAttribute(me:out;
204 anAtt : SSIntersectionAttribute from BOPTools);
208 --------------------------------------------------------------
210 --- PaveBlocks for Split Parts of Edges.
214 anInd1:in out Integer from Standard;
215 anInd2:in out Integer from Standard)
218 --- Sorts the types of shapes with DS-indices
219 --- <anInd1> and <anInd2> in increasing order of
220 --- types of the shapes
222 PerformNewVertices (me:out)
225 IsSuccesstorsComputed (me;
226 iF1:Integer from Standard;
227 iF2:Integer from Standard)
228 returns Boolean from Standard
231 PrepareEdges (me:out)
232 is virtual protected;
234 --- Prepare end paves for each edge
236 PreparePaveBlocks (me:out;
237 aType1: ShapeEnum from TopAbs;
238 aType2: ShapeEnum from TopAbs)
239 is virtual protected;
241 --- Prepare PaveBlocks for each edge (EE-interferences)
243 PreparePaveBlocks (me:out;
244 anE:Integer from Standard)
245 is virtual protected;
247 --- Prepare PaveBlocks for given edge (EE-interferences)
249 RefinePavePool(me:out)
252 --- Refines myPavePool taking into account new Paves obtained from EE algo
254 MakeSplitEdges(me:out)
257 --- Makes split edges from source edges
262 --- Update Lists of PaveBlocks with info about
263 --- indices of split edges that are Same Domain
264 --- with other splits or faces
266 CorrectShrunkRanges(me:out;
267 aSide: Integer from Standard;
268 aPave: Pave from BOPTools;
269 aSR : out ShrunkRange from IntTools)
272 --- Update Shrunk Range <aSR> for Pave <aPave>
274 SplitIndex (me:out; aPB:PaveBlock from BOPTools)
275 returns Integer from Standard
278 --- Returns the Index of Split edge for the PaveBlock <aPB>
280 --- If the PaveBlock is not found, returns 0;
282 IsBlocksCoinside (me;
283 aPB1:PaveBlock from BOPTools;
284 aPB2:PaveBlock from BOPTools)
285 returns Boolean from Standard
288 --- Returns TRUE if the two PaveBlocks have vertices
289 --- that touch each other in terms of Tolerances of
292 --------------------------------------------------------------
294 --- Some of API FUNCTIONS
298 aBid:Integer from Standard;
299 nF1 :Integer from Standard;
300 nF2 :Integer from Standard;
301 aLs :out ListOfInteger from TColStd)
302 returns Integer from Standard;
304 --- For the face <nF1> get all splits that are IN-2D
305 --- to the face <nF2>; The result is in <aLs>
309 nE1 :Integer from Standard;
310 nF2 :Integer from Standard;
311 aLs :out ListOfInteger from TColStd)
312 returns Integer from Standard;
314 --- For the edge <nE1> get all splits that are IN-2D
315 --- to the face <nF1>; The result is in <aLs>
319 nE1 :Integer from Standard;
320 nE2 :Integer from Standard;
321 aLs :out ListOfInteger from TColStd)
322 returns Integer from Standard;
324 --- For the edge <nE1> get all splits that are ON-3D
325 --- to the edge <nE2>; The result is in <aLs>
329 nE1 :Integer from Standard;
330 nF2 :Integer from Standard;
331 aLs :out ListOfInteger from TColStd)
332 returns Integer from Standard;
334 --- For the edge <nE1> get all splits that are ON-3D
335 --- to the face <nF2>; The result is in <aLs>
339 aBid:Integer from Standard;
340 nF1 :Integer from Standard;
341 nF2 :Integer from Standard;
342 aLs :out ListOfInteger from TColStd)
343 returns Integer from Standard;
345 --- For the face <nF1> get all splits that are ON-3D
346 --- to the face <nF2>; The result is in <aLs>
351 aBid:Integer from Standard;
352 nF1 :Integer from Standard;
353 nF2 :Integer from Standard;
354 aLs :out ListOfPaveBlock from BOPTools)
355 returns Integer from Standard;
357 --- For the face <nF1> get all PaveBlocks that are IN-2D
358 --- to the face <nF2>; The result is in <aLs>
363 nE1 :Integer from Standard;
364 nF2 :Integer from Standard;
365 aLs :out ListOfPaveBlock from BOPTools)
366 returns Integer from Standard;
368 --- For the edge <nE1> get all PaveBlocks that are IN-2D
369 --- to the face <nF1>; The result is in <aLs>
374 nE1 :Integer from Standard;
375 nE2 :Integer from Standard;
376 aLs :out ListOfPaveBlock from BOPTools)
377 returns Integer from Standard;
379 --- For the edge <nE1> get all PaveBlocks that are ON-3D
380 --- to the edge <nE2>; The result is in <aLs>
385 nE1 :Integer from Standard;
386 nF2 :Integer from Standard;
387 aLs :out ListOfPaveBlock from BOPTools)
388 returns Integer from Standard;
390 --- For the edge <nE1> get all PaveBlocks that are ON-3D
391 --- to the face <nF2>; The result is in <aLs>
396 aBid:Integer from Standard;
397 nF1 :Integer from Standard;
398 nF2 :Integer from Standard;
399 aLs :out ListOfPaveBlock from BOPTools)
400 returns Integer from Standard;
402 --- For the face <nF1> get all PaveBlocks that are ON-3D
403 --- to the face <nF2>; The result is in <aLs>
407 nV: Integer from Standard)
408 returns Integer from Standard;
410 --- Find for the vertex <nV> SD-vertex (if possible) and return
411 --- its DS-index. Otherwise it returns 0.
414 ---------------------------------------------------------------
416 --- Section Edges. Protected Block.
422 --- Make Pave Blocks for intersection curves
424 MakeAloneVertices(me:out)
427 --- Make vertices that are place of intersection
430 PutPaveOnCurve(me:out;
431 aPaveSet: PaveSet from BOPTools;
432 aTolR3D : Real from Standard;
433 aBCurve :out Curve from BOPTools)
436 --- Among Paves from <aPaveSet> find ones that belong
437 --- to intersection curve <aBCurve> with 3D-tolerance
440 PutPaveOnCurve(me:out;
441 aPave : Pave from BOPTools;
442 aTolR3D : Real from Standard;
443 aBCurve :out Curve from BOPTools)
446 --- Try to put Pave <aPave> on intersection curve <aBCurve>
447 --- with 3D-tolerance value <aTolR3D>
450 PutPavesOnCurves(me:out)
453 PrepareSetForFace(me:out;
454 nF1 :Integer from Standard;
455 nF2 :Integer from Standard;
456 aPaveSet:out PaveSet from BOPTools);
458 --- For couple of faces <nF1>, <nF2> prepare set of all paves
459 --- of all edges <aPaveSet>
461 MakeSectionEdges(me:out)
464 --- For all inrefered faces make section edges from
465 --- intersection curves and corresp. Paves on them
467 PutBoundPaveOnCurve (me:out;
468 aBC :out Curve from BOPTools;
469 aFF :out SSInterference from BOPTools)
472 --- Try to put own bounds of the curve on the curve <aBC>
474 PutBoundPaveOnCurve (me:out;
476 aT : Real from Standard;
477 aBC :out Curve from BOPTools;
478 aFF :out SSInterference from BOPTools)
481 --- Try to put 3D-point <aP> (parameter aT) on the curve <aBC>
483 PutBoundPaveOnCurveSpec (me:out;
484 aBC :out Curve from BOPTools;
485 aFF :out SSInterference from BOPTools)
488 --- Try to put own bounds of the curve on the curve <aBC>
490 PutBoundPaveOnCurveSpec (me:out;
492 aT : Real from Standard;
493 aBC :out Curve from BOPTools;
494 aFF :out SSInterference from BOPTools)
497 --- Try to put 3D-point <aP> (parameter aT) on the curve <aBC>
500 --modified by NIZNHY-PKV Thu Oct 20 07:17:11 2011f
501 PutClosingPaveOnCurve (me:out;
502 aBC :out Curve from BOPTools;
503 aFF :out SSInterference from BOPTools)
506 --- Put paves on the curve <aBC> in case when <aBC>
507 -- is closed 3D-curve
509 --modified by NIZNHY-PKV Thu Oct 20 07:17:11 2011t
513 aTpV: Real from Standard;
514 aPS: PaveSet from BOPTools;
515 aPV:out Pave from BOPTools)
516 returns Boolean from Standard
519 --- Returns TRUE if 3D-point <aP> coinsides with some Pave
520 --- from <aPS> (with 3D-tolerance value <aTpV>);
521 --- In TRUE case <aPV> will contain the Pave .
523 CheckCoincidence(me:out;
524 aPB: PaveBlock from BOPTools;
525 aFF: SSInterference from BOPTools)
526 returns Boolean from Standard
529 --- Returns TRUE if PaveBlock <aPB> lays on the faces
530 --- from FF-interference <aFF>
532 CheckIntermediatePoint(me:out;
533 aPB : PaveBlock from BOPTools;
534 aPBR: PaveBlock from BOPTools;
535 aTol: Real from Standard)
536 returns Integer from Standard
539 --- Returns 0 if some arbitrary intermediate point from
540 --- PaveBlock <aPB> lays on the PaveBlock <aPBR>
541 --- (with 3D-tolerance value <aTol>)
544 CheckFacePaves(me:out;
545 aV : Vertex from TopoDS;
546 nF: Integer from Standard)
547 returns Integer from Standard
552 StickVertices (me:out;
553 nF1: Integer from Standard;
554 nF2: Integer from Standard;
555 aMV:out IndexedMapOfInteger from TColStd)
560 ExpectedPoolLength(me)
561 returns Integer from Standard
564 --- Returns the value of expected length of array of interferences
567 RestrictCurveIn2d(me: in out; nE, nF1, nF2 : Integer from Standard;
568 theTolerance: Real from Standard;
569 theBC : in out Curve from BOPTools)
572 RecomputeCommonBlocks(me: in out; nE: Integer from Standard)
575 ExtendedTolerance(me:out;
576 nV : Integer from Standard;
577 aTolExt : out Real from Standard)
578 returns Boolean from Standard
583 myIntrPool : PInterferencePool from BOPTools
585 myDS : PShapesDataStructure from BooleanOperations
587 myPavePool : PavePool from BOPTools
589 myPavePoolNew : PavePool from BOPTools
591 myCommonBlockPool : CommonBlockPool from BOPTools
593 mySplitShapesPool : SplitShapesPool from BOPTools
595 mySectionAttribute : SSIntersectionAttribute from BOPTools
597 myNbSources : Integer from Standard
599 myNbEdges : Integer from Standard
601 myIsDone : Boolean from Standard
603 myDSIt : IteratorOfCoupleOfShape from BOPTools
605 myContext : Context from IntTools