1 -- Created on: 1995-07-02
2 -- Created by: Laurent BUCHARD
3 -- Copyright (c) 1995-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 class HContTool from Contap
19 ---Purpose: Tool for the intersection between 2 surfaces.
20 -- Regroupe pour l instant les methodes hors Adaptor3d...
26 HVertex from Adaptor3d,
27 HCurve2d from Adaptor2d,
28 HSurface from Adaptor3d,
29 HCurve2dTool from Contap,
30 HSurfaceTool from Adaptor3d
34 NbSamplesU(myclass; S: HSurface from Adaptor3d; u1,u2: Real from Standard)
35 returns Integer from Standard;
37 NbSamplesV(myclass; S: HSurface from Adaptor3d; v1,v2: Real from Standard)
38 returns Integer from Standard;
40 -- Methodes pour recherche des points interieurs
42 NbSamplePoints(myclass; S: HSurface from Adaptor3d)
44 returns Integer from Standard;
47 SamplePoint(myclass; S : HSurface from Adaptor3d;
48 Index: Integer from Standard;
49 U,V: out Real from Standard);
52 -- Methodes sur un arc de restriction
54 HasBeenSeen(myclass; C: HCurve2d from Adaptor2d)
56 ---Purpose: Returns True if all the intersection point and edges
57 -- are known on the Arc.
58 -- The intersection point are given as vertices.
59 -- The intersection edges are given as intervals between
62 returns Boolean from Standard;
64 NbSamplesOnArc(myclass; A: HCurve2d from Adaptor2d)
66 ---Purpose: returns the number of points which is used to make
67 -- a sample on the arc. this number is a function of
68 -- the Surface and the CurveOnSurface complexity.
70 returns Integer from Standard;
73 Bounds(myclass; C: HCurve2d from Adaptor2d;
74 Ufirst,Ulast: out Real from Standard);
76 ---Purpose: Returns the parametric limits on the arc C.
77 -- These limits must be finite : they are either
78 -- the real limits of the arc, for a finite arc,
79 -- or a bounding box for an infinite arc.
82 Project(myclass; C: HCurve2d from Adaptor2d;
84 Paramproj: out Real from Standard;
85 Ptproj : out Pnt2d from gp)
87 ---Purpose: Projects the point P on the arc C.
88 -- If the methods returns Standard_True, the projection is
89 -- successful, and Paramproj is the parameter on the arc
90 -- of the projected point, Ptproj is the projected Point.
91 -- If the method returns Standard_False, Param proj and Ptproj
92 -- are not significant.
95 returns Boolean from Standard;
98 -- Methods on a vertex
101 Tolerance(myclass; V: HVertex from Adaptor3d; C: HCurve2d from Adaptor2d)
103 ---Purpose: Returns the parametric tolerance used to consider
104 -- that the vertex and another point meet, i-e
105 -- if Abs(parameter(Vertex) - parameter(OtherPnt))<=
106 -- Tolerance, the points are "merged".
108 returns Real from Standard;
111 Parameter(myclass; V: HVertex from Adaptor3d; C: HCurve2d from Adaptor2d)
113 ---Purpose: Returns the parameter of the vertex V on the arc A.
115 returns Real from Standard;
118 -- The following methods are used when HasBeenSeen returns Standard_True
120 NbPoints(myclass; C: HCurve2d from Adaptor2d)
122 ---Purpose: Returns the number of intersection points on the arc A.
124 returns Integer from Standard;
127 Value(myclass; C: HCurve2d from Adaptor2d; Index: Integer from Standard;
128 Pt: out Pnt from gp; Tol: out Real from Standard;
129 U: out Real from Standard);
131 ---Purpose: Returns the value (Pt), the tolerance (Tol), and
132 -- the parameter (U) on the arc A , of the intersection
133 -- point of range Index.
136 IsVertex(myclass; C: HCurve2d from Adaptor2d;
137 Index: Integer from Standard)
139 ---Purpose: Returns True if the intersection point of range Index
140 -- corresponds with a vertex on the arc A.
142 returns Boolean from Standard;
145 Vertex(myclass; C: HCurve2d from Adaptor2d; Index: Integer from Standard;
146 V: out HVertex from Adaptor3d);
148 ---Purpose: When IsVertex returns True, this method returns the
149 -- vertex on the arc A.
152 NbSegments(myclass; C: HCurve2d from Adaptor2d)
154 ---Purpose: returns the number of part of A solution of the
155 -- of intersection problem.
157 returns Integer from Standard;
160 HasFirstPoint(myclass; C: HCurve2d from Adaptor2d;
161 Index: Integer from Standard;
162 IndFirst: out Integer from Standard)
164 ---Purpose: Returns True when the segment of range Index is not
165 -- open at the left side. In that case, IndFirst is the
166 -- range in the list intersection points (see NbPoints)
167 -- of the one which defines the left bound of the segment.
168 -- Otherwise, the method has to return False, and IndFirst
171 returns Boolean from Standard;
174 HasLastPoint(myclass; C: HCurve2d from Adaptor2d;
175 Index: Integer from Standard;
176 IndLast: out Integer from Standard)
178 ---Purpose: Returns True when the segment of range Index is not
179 -- open at the right side. In that case, IndLast is the
180 -- range in the list intersection points (see NbPoints)
181 -- of the one which defines the right bound of the segment.
182 -- Otherwise, the method has to return False, and IndLast
185 returns Boolean from Standard;
188 IsAllSolution(myclass; C: HCurve2d from Adaptor2d)
190 ---Purpose: Returns True when the whole restriction is solution
191 -- of the intersection problem.
193 returns Boolean from Standard;