1 -- File: MakeArcOfCircle.cdl
2 -- Created: Mon Sep 28 11:50:14 1992
5 ---Copyright: Matra Datavision 1992
7 class MakeArcOfCircle from GC inherits Root from GC
8 ---Purpose: Implements construction algorithms for an
9 -- arc of circle in 3D space. The result is a Geom_TrimmedCurve curve.
10 -- A MakeArcOfCircle object provides a framework for:
11 -- - defining the construction of the arc of circle,
12 -- - implementing the construction algorithm, and
13 -- - consulting the results. In particular, the
14 -- Value function returns the constructed arc of circle.
22 TrimmedCurve from Geom
24 raises NotDone from StdFail
28 Create(Circ : Circ from gp ;
29 Alpha1, Alpha2 : Real from Standard ;
30 Sense : Boolean from Standard ) returns MakeArcOfCircle;
31 ---Purpose: Make an arc of circle (TrimmedCurve from Geom) from
32 -- a circle between two angles Alpha1 and Alpha2
35 Create(Circ : Circ from gp ;
37 Alpha : Real from Standard ;
38 Sense : Boolean from Standard ) returns MakeArcOfCircle;
39 ---Purpose: Make an arc of circle (TrimmedCurve from Geom) from
40 -- a circle between point <P> and the angle Alpha
43 Create(Circ : Circ from gp ;
46 Sense : Boolean from Standard ) returns MakeArcOfCircle;
47 ---Purpose: Make an arc of circle (TrimmedCurve from Geom) from
48 -- a circle between two points P1 and P2.
50 Create(P1 : Pnt from gp ;
53 returns MakeArcOfCircle;
54 ---Purpose: Make an arc of circle (TrimmedCurve from Geom) from
55 -- three points P1,P2,P3 between two points P1 and P2.
57 Create(P1 : Pnt from gp ;
60 returns MakeArcOfCircle;
61 ---Purpose: Make an arc of circle (TrimmedCurve from Geom) from
62 -- two points P1,P2 and the tangente to the solution at
64 -- The orientation of the arc is:
65 -- - the sense determined by the order of the points P1, P3 and P2;
66 -- - the sense defined by the vector V; or
67 -- - for other syntaxes:
68 -- - the sense of Circ if Sense is true, or
69 -- - the opposite sense if Sense is false.
70 -- Note: Alpha1, Alpha2 and Alpha are angle values, given in radians.
72 -- If an error occurs (that is, when IsDone returns
73 -- false), the Status function returns:
74 -- - gce_ConfusedPoints if:
75 -- - any 2 of the 3 points P1, P2 and P3 are coincident, or
76 -- - P1 and P2 are coincident; or
77 -- - gce_IntersectionError if:
78 -- - P1, P2 and P3 are collinear and not coincident, or
79 -- - the vector defined by the points P1 and
80 -- P2 is collinear with the vector V.
82 Value(me) returns TrimmedCurve from Geom
85 ---Purpose: Returns the constructed arc of circle.
86 -- Exceptions StdFail_NotDone if no arc of circle is constructed.
89 Operator(me) returns TrimmedCurve from Geom
92 ---C++: alias "Standard_EXPORT operator Handle_Geom_TrimmedCurve() const;"
96 TheArc : TrimmedCurve from Geom;
97 --The solution from Geom.