1 -- Created on: 1992-03-02
2 -- Created by: Laurent BUCHARD
3 -- Copyright (c) 1992-1999 Matra Datavision
4 -- Copyright (c) 1999-2012 OPEN CASCADE SAS
6 -- The content of this file is subject to the Open CASCADE Technology Public
7 -- License Version 6.5 (the "License"). You may not use the content of this file
8 -- except in compliance with the License. Please obtain a copy of the License
9 -- at http://www.opencascade.org and read it completely before using this file.
11 -- The Initial Developer of the Original Code is Open CASCADE S.A.S., having its
12 -- main offices at: 1, place des Freres Montgolfier, 78280 Guyancourt, France.
14 -- The Original Code and all software distributed under the License is
15 -- distributed on an "AS IS" basis, without warranty of any kind, and the
16 -- Initial Developer hereby disclaims all such warranties, including without
17 -- limitation, any warranties of merchantability, fitness for a particular
18 -- purpose or non-infringement. Please see the License for the specific terms
19 -- and conditions governing the rights and limitations under the License.
23 generic class Intersector from IntImpParGen (
24 ImpTool as any; -- as ImpTool from IntImpParGen
26 ParTool as any; -- as ParTool from IntImpParGen(ParCurve)
27 ProjectOnPCurveTool as any) -- as ProjectOnPCurveToolGen from IntCurve
29 inherits Intersection from IntRes2d
31 ---Purpose: Calculates all the IntersectionPoints
32 -- and IntersectionSegments between an implicit curve
33 -- (see class ImpTool) and a parametrised curve (see class
34 -- ParTool) on their domains.
35 -- The results of the intersection are stored in the
36 -- Intersection class from IntRes2d.
37 -- The parametrised curve has to be bounded (the domain
38 -- of this curve must verify HasFirstPoint returns True
39 -- and HasLastPoint returns True).
43 uses IntersectionPoint from IntRes2d,
44 IntersectionSegment from IntRes2d,
45 SequenceOfIntersectionPoint from IntRes2d,
46 SequenceOfIntersectionSegment from IntRes2d,
49 Array1OfReal from TColStd
52 raises ConstructionError from Standard
55 class MyImpParTool instantiates ImpParTool from IntImpParGen(
66 ---Purpose: Empty constructor.
68 returns Intersector from IntImpParGen;
71 Create ( ITool : ImpTool;
72 Dom1 : Domain from IntRes2d;
74 Dom2 : Domain from IntRes2d;
75 TolConf,Tol: Real from Standard)
77 ---Purpose: Intersection between an implicit curve and
78 -- a parametrised curve.
79 -- The exception ConstructionError is raised if the domain
80 -- of the parametrised curve does not verify HasFirstPoint
81 -- and HasLastPoint return True.
83 returns Intersector from IntImpParGen
84 raises ConstructionError from Standard;
89 Dom1 : Domain from IntRes2d;
91 Dom2 : Domain from IntRes2d;
92 TolConf,Tol: Real from Standard)
94 ---Purpose: Intersection between an implicit curve and
95 -- a parametrised curve.
96 -- The exception ConstructionError is raised if the domain
97 -- of the parametrised curve does not verify HasFirstPoint
98 -- and HasLastPoint return True.
101 raises ConstructionError from Standard
105 parameter : Real from Standard ;
106 point : in out Pnt2d from gp;
107 TheParCurev : ParCurve;
108 TheImpTool : ImpTool)
109 returns Real from Standard
114 parameter : Real from Standard ;
115 point : in out Pnt2d from gp ;
116 TheImpTool : ImpTool ;
117 ParCurve : ParCurve ;
118 TheParCurveDomain : Domain from IntRes2d ;
119 V0 : Real from Standard ;
120 V1 : Real from Standard ;
121 Tolerance : Real from Standard )
122 returns Real from Standard
125 And_Domaine_Objet1_Intersections ( me ;
126 TheImpTool : ImpTool ;
127 TheParCurve : ParCurve ;
128 TheImpCurveDomain : Domain from IntRes2d ;
129 TheParCurveDomain : Domain from IntRes2d ;
130 NbResultats : in out Integer from Standard ;
131 Inter2_And_Domain2 : in out Array1OfReal from TColStd ;
132 Inter1 : in out Array1OfReal from TColStd ;
133 Resultat1 : in out Array1OfReal from TColStd ;
134 Resultat2 : in out Array1OfReal from TColStd ;
135 EpsNul : Real from Standard )