7fd59977 |
1 | -- File: ProjectOnPConicTool.cdl |
2 | -- Created: Tue Oct 13 18:36:43 1992 |
3 | -- Author: Laurent BUCHARD |
4 | -- <lbr@sdsun2> |
5 | ---Copyright: Matra Datavision 1992 |
6 | |
7 | |
8 | |
9 | |
10 | private class ProjectOnPConicTool from IntCurve |
11 | |
12 | ---Purpose: This class provides a tool which computes the parameter |
13 | -- of a point near a parametric conic. |
14 | |
15 | uses Pnt2d from gp, |
16 | PConic from IntCurve |
17 | is |
18 | |
19 | FindParameter(myclass; C: PConic from IntCurve; |
20 | Pnt: Pnt2d from gp; |
21 | Tol: Real from Standard) |
22 | |
23 | --- Purpose: Returns the parameter V of the point on the |
24 | -- parametric curve corresponding to the Point Pnt. The |
25 | -- Correspondance between Pnt and the point P(V) on the |
26 | -- parametric curve must be coherent with the way of |
27 | -- determination of the signed distance between a point and |
28 | -- the implicit curve. Tol is the tolerance on the distance |
29 | -- between a point and the parametrised curve. In that case, |
30 | -- no bounds are given. The research of the rigth parameter |
31 | -- has to be made on the natural parametric domain of the |
32 | -- curve. |
33 | |
34 | returns Real from Standard; |
35 | |
36 | |
37 | FindParameter(myclass; C: PConic from IntCurve; |
38 | Pnt: Pnt2d from gp; |
39 | LowParameter,HighParameter,Tol: Real from Standard) |
40 | |
41 | --- Purpose: Returns the parameter V of the point on the |
42 | -- parametric curve corresponding to the Point Pnt. The |
43 | -- Correspondance between Pnt and the point P(V) on the |
44 | -- parametric curve must be coherent with the way of |
45 | -- determination of the signed distance between a point and |
46 | -- the implicit curve. Tol is the tolerance on the distance |
47 | -- between a point and the parametrised curve. LowParameter |
48 | -- and HighParameter give the boundaries of the interval in |
49 | -- wich the parameter certainly lies. These parameters are |
50 | -- given to implement a more efficient algoritm. So, it is |
51 | -- not necessary to check that the returned value verifies |
52 | -- LowParameter <= Value <= HighParameter. |
53 | |
54 | returns Real from Standard; |
55 | |
56 | end ProjectOnPConicTool; |