Commit | Line | Data |
---|---|---|
b311480e | 1 | -- Created on: 1995-07-02 |
2 | -- Created by: Laurent BUCHARD | |
3 | -- Copyright (c) 1995-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 | -- |
973c2be1 | 8 | -- This library is free software; you can redistribute it and / or modify it |
9 | -- under the terms of the GNU Lesser General Public 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. | |
b311480e | 13 | -- |
973c2be1 | 14 | -- Alternatively, this file may be used under the terms of Open CASCADE |
15 | -- commercial license or contractual agreement. | |
7fd59977 | 16 | |
17 | class HInterTool from IntPatch | |
18 | ||
19 | ---Purpose: Tool for the intersection between 2 surfaces. | |
20 | -- Regroupe pour l instant les methodes hors Adaptor3d... | |
21 | ||
22 | uses | |
23 | HVertex from Adaptor3d, | |
24 | HCurve2d from Adaptor2d, | |
25 | HSurface from Adaptor3d, | |
26 | Pnt2d from gp, | |
27 | Pnt from gp | |
28 | ||
29 | is | |
30 | ||
1ef32e96 | 31 | Create returns HInterTool from IntPatch; |
7fd59977 | 32 | |
33 | -- Pour polyedres | |
34 | ||
35 | SingularOnUMin(myclass; S:HSurface from Adaptor3d) | |
36 | returns Boolean from Standard; | |
37 | ---C++: inline | |
38 | ||
39 | SingularOnUMax(myclass; S:HSurface from Adaptor3d) | |
40 | returns Boolean from Standard; | |
41 | ---C++: inline | |
42 | ||
43 | SingularOnVMin(myclass; S:HSurface from Adaptor3d) | |
44 | returns Boolean from Standard; | |
45 | ---C++: inline | |
46 | ||
47 | SingularOnVMax(myclass; S:HSurface from Adaptor3d) | |
48 | returns Boolean from Standard; | |
49 | ---C++: inline | |
50 | ||
51 | NbSamplesU(myclass; S: HSurface from Adaptor3d; u1,u2: Real from Standard) | |
52 | returns Integer from Standard; | |
53 | ||
54 | NbSamplesV(myclass; S: HSurface from Adaptor3d; v1,v2: Real from Standard) | |
55 | returns Integer from Standard; | |
56 | ||
57 | -- Methodes pour recherche des points interieurs | |
58 | ||
1ef32e96 | 59 | NbSamplePoints(me: in out; S: HSurface from Adaptor3d) |
7fd59977 | 60 | |
61 | returns Integer from Standard; | |
62 | ||
63 | ||
1ef32e96 | 64 | SamplePoint(me; S: HSurface from Adaptor3d; |
7fd59977 | 65 | Index: Integer from Standard; |
66 | U,V: out Real from Standard); | |
67 | ||
68 | ||
69 | -- Classify(myclass; S: HSurface from Adaptor3d; | |
70 | -- U,V: Real from Standard) | |
71 | -- | |
72 | -- returns State from TopAbs; | |
73 | ||
74 | ||
75 | -- Methodes sur un arc de restriction | |
76 | ||
77 | HasBeenSeen(myclass; C: HCurve2d from Adaptor2d) | |
78 | ||
79 | ---Purpose: Returns True if all the intersection point and edges | |
80 | -- are known on the Arc. | |
81 | -- The intersection point are given as vertices. | |
82 | -- The intersection edges are given as intervals between | |
83 | -- two vertices. | |
84 | ||
85 | returns Boolean from Standard; | |
86 | ||
87 | NbSamplesOnArc(myclass; A: HCurve2d from Adaptor2d) | |
88 | ||
89 | ---Purpose: returns the number of points which is used to make | |
90 | -- a sample on the arc. this number is a function of | |
91 | -- the Surface and the CurveOnSurface complexity. | |
92 | ||
93 | returns Integer from Standard; | |
94 | ||
95 | ||
96 | Bounds(myclass; C: HCurve2d from Adaptor2d; | |
97 | Ufirst,Ulast: out Real from Standard); | |
98 | ||
99 | ---Purpose: Returns the parametric limits on the arc C. | |
100 | -- These limits must be finite : they are either | |
101 | -- the real limits of the arc, for a finite arc, | |
102 | -- or a bounding box for an infinite arc. | |
103 | ||
104 | ||
105 | Project(myclass; C: HCurve2d from Adaptor2d; | |
106 | P: Pnt2d from gp; | |
107 | Paramproj: out Real from Standard; | |
108 | Ptproj : out Pnt2d from gp) | |
109 | ||
110 | ---Purpose: Projects the point P on the arc C. | |
111 | -- If the methods returns Standard_True, the projection is | |
112 | -- successful, and Paramproj is the parameter on the arc | |
113 | -- of the projected point, Ptproj is the projected Point. | |
114 | -- If the method returns Standard_False, Param proj and Ptproj | |
115 | -- are not significant. | |
116 | -- | |
117 | ||
118 | returns Boolean from Standard; | |
119 | ||
120 | ||
121 | -- Methods on a vertex | |
122 | ||
123 | ||
124 | Tolerance(myclass; V: HVertex from Adaptor3d; C: HCurve2d from Adaptor2d) | |
125 | ||
126 | ---Purpose: Returns the parametric tolerance used to consider | |
127 | -- that the vertex and another point meet, i-e | |
128 | -- if Abs(parameter(Vertex) - parameter(OtherPnt))<= | |
129 | -- Tolerance, the points are "merged". | |
130 | ||
131 | returns Real from Standard; | |
132 | ||
133 | ||
134 | Parameter(myclass; V: HVertex from Adaptor3d; C: HCurve2d from Adaptor2d) | |
135 | ||
136 | ---Purpose: Returns the parameter of the vertex V on the arc A. | |
137 | ||
138 | returns Real from Standard; | |
139 | ||
140 | ||
141 | -- The following methods are used when HasBeenSeen returns Standard_True | |
142 | ||
143 | NbPoints(myclass; C: HCurve2d from Adaptor2d) | |
144 | ||
145 | ---Purpose: Returns the number of intersection points on the arc A. | |
146 | ||
147 | returns Integer from Standard; | |
148 | ||
149 | ||
150 | Value(myclass; C: HCurve2d from Adaptor2d; Index: Integer from Standard; | |
151 | Pt: out Pnt from gp; Tol: out Real from Standard; | |
152 | U: out Real from Standard); | |
153 | ||
154 | ---Purpose: Returns the value (Pt), the tolerance (Tol), and | |
155 | -- the parameter (U) on the arc A , of the intersection | |
156 | -- point of range Index. | |
157 | ||
158 | ||
159 | IsVertex(myclass; C: HCurve2d from Adaptor2d; | |
160 | Index: Integer from Standard) | |
161 | ||
162 | ---Purpose: Returns True if the intersection point of range Index | |
163 | -- corresponds with a vertex on the arc A. | |
164 | ||
165 | returns Boolean from Standard; | |
166 | ||
167 | ||
168 | Vertex(myclass; C: HCurve2d from Adaptor2d; Index: Integer from Standard; | |
169 | V: out HVertex from Adaptor3d); | |
170 | ||
171 | ---Purpose: When IsVertex returns True, this method returns the | |
172 | -- vertex on the arc A. | |
173 | ||
174 | ||
175 | NbSegments(myclass; C: HCurve2d from Adaptor2d) | |
176 | ||
177 | ---Purpose: returns the number of part of A solution of the | |
178 | -- of intersection problem. | |
179 | ||
180 | returns Integer from Standard; | |
181 | ||
182 | ||
183 | HasFirstPoint(myclass; C: HCurve2d from Adaptor2d; | |
184 | Index: Integer from Standard; | |
185 | IndFirst: out Integer from Standard) | |
186 | ||
187 | ---Purpose: Returns True when the segment of range Index is not | |
188 | -- open at the left side. In that case, IndFirst is the | |
189 | -- range in the list intersection points (see NbPoints) | |
190 | -- of the one which defines the left bound of the segment. | |
191 | -- Otherwise, the method has to return False, and IndFirst | |
192 | -- has no meaning. | |
193 | ||
194 | returns Boolean from Standard; | |
195 | ||
196 | ||
197 | HasLastPoint(myclass; C: HCurve2d from Adaptor2d; | |
198 | Index: Integer from Standard; | |
199 | IndLast: out Integer from Standard) | |
200 | ||
201 | ---Purpose: Returns True when the segment of range Index is not | |
202 | -- open at the right side. In that case, IndLast is the | |
203 | -- range in the list intersection points (see NbPoints) | |
204 | -- of the one which defines the right bound of the segment. | |
205 | -- Otherwise, the method has to return False, and IndLast | |
206 | -- has no meaning. | |
207 | ||
208 | returns Boolean from Standard; | |
209 | ||
210 | ||
211 | IsAllSolution(myclass; C: HCurve2d from Adaptor2d) | |
212 | ||
213 | ---Purpose: Returns True when the whole restriction is solution | |
214 | -- of the intersection problem. | |
215 | ||
216 | returns Boolean from Standard; | |
217 | ||
1ef32e96 RL |
218 | fields |
219 | ||
220 | uinf,vinf,usup,vsup: Real from Standard; | |
7fd59977 | 221 | |
222 | end HInterTool; |