1 -- Created on: 1992-03-02
2 -- Created by: Laurent BUCHARD
3 -- Copyright (c) 1992-1999 Matra Datavision
4 -- Copyright (c) 1999-2014 OPEN CASCADE SAS
6 -- This file is part of Open CASCADE Technology software library.
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.
14 -- Alternatively, this file may be used under the terms of Open CASCADE
15 -- commercial license or contractual agreement.
17 generic class Intersector from IntImpParGen (
18 ImpTool as any; -- as ImpTool from IntImpParGen
20 ParTool as any; -- as ParTool from IntImpParGen(ParCurve)
21 ProjectOnPCurveTool as any) -- as ProjectOnPCurveToolGen from IntCurve
23 inherits Intersection from IntRes2d
25 ---Purpose: Calculates all the IntersectionPoints
26 -- and IntersectionSegments between an implicit curve
27 -- (see class ImpTool) and a parametrised curve (see class
28 -- ParTool) on their domains.
29 -- The results of the intersection are stored in the
30 -- Intersection class from IntRes2d.
31 -- The parametrised curve has to be bounded (the domain
32 -- of this curve must verify HasFirstPoint returns True
33 -- and HasLastPoint returns True).
37 uses IntersectionPoint from IntRes2d,
38 IntersectionSegment from IntRes2d,
39 SequenceOfIntersectionPoint from IntRes2d,
40 SequenceOfIntersectionSegment from IntRes2d,
43 Array1OfReal from TColStd
46 raises ConstructionError from Standard
49 class MyImpParTool instantiates ImpParTool from IntImpParGen(
60 ---Purpose: Empty constructor.
62 returns Intersector from IntImpParGen;
65 Create ( ITool : ImpTool;
66 Dom1 : Domain from IntRes2d;
68 Dom2 : Domain from IntRes2d;
69 TolConf,Tol: Real from Standard)
71 ---Purpose: Intersection between an implicit curve and
72 -- a parametrised curve.
73 -- The exception ConstructionError is raised if the domain
74 -- of the parametrised curve does not verify HasFirstPoint
75 -- and HasLastPoint return True.
77 returns Intersector from IntImpParGen
78 raises ConstructionError from Standard;
83 Dom1 : Domain from IntRes2d;
85 Dom2 : Domain from IntRes2d;
86 TolConf,Tol: Real from Standard)
88 ---Purpose: Intersection between an implicit curve and
89 -- a parametrised curve.
90 -- The exception ConstructionError is raised if the domain
91 -- of the parametrised curve does not verify HasFirstPoint
92 -- and HasLastPoint return True.
95 raises ConstructionError from Standard
99 parameter : Real from Standard ;
100 point : in out Pnt2d from gp;
101 TheParCurev : ParCurve;
102 TheImpTool : ImpTool)
103 returns Real from Standard
108 parameter : Real from Standard ;
109 point : in out Pnt2d from gp ;
110 TheImpTool : ImpTool ;
111 ParCurve : ParCurve ;
112 TheParCurveDomain : Domain from IntRes2d ;
113 V0 : Real from Standard ;
114 V1 : Real from Standard ;
115 Tolerance : Real from Standard )
116 returns Real from Standard
119 And_Domaine_Objet1_Intersections ( me ;
120 TheImpTool : ImpTool ;
121 TheParCurve : ParCurve ;
122 TheImpCurveDomain : Domain from IntRes2d ;
123 TheParCurveDomain : Domain from IntRes2d ;
124 NbResultats : in out Integer from Standard ;
125 Inter2_And_Domain2 : in out Array1OfReal from TColStd ;
126 Inter1 : in out Array1OfReal from TColStd ;
127 Resultat1 : in out Array1OfReal from TColStd ;
128 Resultat2 : in out Array1OfReal from TColStd ;
129 EpsNul : Real from Standard )