0024428: Implementation of LGPL license
[occt.git] / src / BRepPrimAPI / BRepPrimAPI_MakeCone.cdl
CommitLineData
b311480e 1-- Created on: 1993-07-21
2-- Created by: Remi LEQUETTE
3-- Copyright (c) 1993-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
17class MakeCone from BRepPrimAPI inherits MakeOneAxis from BRepPrimAPI
18
19 ---Purpose: Describes functions to build cones or portions of cones.
20 -- A MakeCone object provides a framework for:
21 -- - defining the construction of a cone,
22 -- - implementing the construction algorithm, and
23 -- - consulting the result.
24
25uses
26 Ax2 from gp,
27 Cone from BRepPrim,
28 OneAxis from BRepPrim
29
30raises
31 DomainError from Standard
32
33is
34 Create(R1, R2, H : Real)
35 returns MakeCone from BRepPrimAPI
36 ---Purpose: Make a cone of height H radius R1 in the plane z =
37 -- 0, R2 in the plane Z = H. R1 and R2 may be null.
38 ---Level: Public
39 raises
40 DomainError from Standard; -- if H <= Precision::Confusion()
41
42 Create(R1, R2, H, angle : Real)
43 returns MakeCone from BRepPrimAPI
44 ---Purpose: Make a cone of height H radius R1 in the plane z =
45 -- 0, R2 in the plane Z = H. R1 and R2 may be null.
46 -- Take a section of <angle>
47 ---Level: Public
48 raises
49 DomainError from Standard; -- if H <= Precision::Confusion()
50
51 Create(Axes : Ax2 from gp; R1, R2, H : Real)
52 returns MakeCone from BRepPrimAPI
53 ---Purpose: Make a cone of height H radius R1 in the plane z =
54 -- 0, R2 in the plane Z = H. R1 and R2 may be null.
55 ---Level: Public
56 raises
57 DomainError from Standard; -- if H <= Precision::Confusion()
58
59 Create(Axes : Ax2 from gp; R1, R2, H, angle : Real)
60 returns MakeCone from BRepPrimAPI
61 ---Purpose: Make a cone of height H radius R1 in the plane z =
62 -- 0, R2 in the plane Z = H. R1 and R2 may be null.
63 -- Take a section of <angle>
64 ---Level: Public
65 raises
66 DomainError from Standard; -- if H <= Precision::Confusion()
67
68 ---Purpose: Constructs a cone, or a portion of a cone, of height H,
69 -- and radius R1 in the plane z = 0 and R2 in the plane
70 -- z = H. The result is a sharp cone if R1 or R2 is equal to 0.
71 -- The cone is constructed about the "Z Axis" of either:
72 -- - the global coordinate system, or
73 -- - the local coordinate system Axes.
74 -- It is limited in these coordinate systems as follows:
75 -- - in the v parametric direction (the Z coordinate), by
76 -- the two parameter values 0 and H,
77 -- - and in the u parametric direction (defined by the
78 -- angle of rotation around the Z axis), in the case of a
79 -- portion of a cone, by the two parameter values 0 and
80 -- angle. Angle is given in radians.
81 -- The resulting shape is composed of:
82 -- - a lateral conical face
83 -- - two planar faces in the planes z = 0 and z = H,
84 -- or only one planar face in one of these two planes if a
85 -- radius value is null (in the case of a complete cone,
86 -- these faces are circles), and
87 -- - and in the case of a portion of a cone, two planar
88 -- faces to close the shape. (either two parallelograms or
89 -- two triangles, in the planes u = 0 and u = angle).
90 -- Exceptions
91 -- Standard_DomainError if:
92 -- - H is less than or equal to Precision::Confusion(), or
93 -- - the half-angle at the apex of the cone, defined by
94 -- R1, R2 and H, is less than Precision::Confusion()/H, or greater than
95 -- (Pi/2)-Precision::Confusion()/H.f
96
97 OneAxis(me : in out) returns Address;
98 ---Purpose: Returns the algorithm.
99 ---Level: Public
100
101 Cone(me : in out) returns Cone from BRepPrim
102 ---Purpose: Returns the algorithm.
103 --
104 ---C++: return &
105 ---Level: Public
106 is static;
107
108fields
109
110 myCone : Cone from BRepPrim;
111
112end MakeCone;