1 -- Created on: 1993-07-21
2 -- Created by: Remi LEQUETTE
3 -- Copyright (c) 1993-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
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.
14 -- Alternatively, this file may be used under the terms of Open CASCADE
15 -- commercial license or contractual agreement.
17 class MakeSolid from BRepBuilderAPI inherits MakeShape from BRepBuilderAPI
19 ---Purpose: Describes functions to build a solid from shells.
20 -- A solid is made of one shell, or a series of shells, which
21 -- do not intersect each other. One of these shells
22 -- constitutes the outside skin of the solid. It may be closed
23 -- (a finite solid) or open (an infinite solid). Other shells
24 -- form hollows (cavities) in these previous ones. Each
25 -- must bound a closed volume.
26 -- A MakeSolid object provides a framework for:
27 -- - defining and implementing the construction of a solid, and
28 -- - consulting the result.
32 CompSolid from TopoDS,
35 MakeSolid from BRepLib
43 ---Purpose: Initializes the construction of a solid. An empty solid is
44 -- considered to cover the whole space. The Add function
45 -- is used to define shells to bound it.
46 returns MakeSolid from BRepBuilderAPI;
48 ----------------------------------------------
50 ----------------------------------------------
52 Create(S : CompSolid from TopoDS)
53 ---Purpose: Make a solid from a CompSolid.
55 returns MakeSolid from BRepBuilderAPI;
57 -- this algorithm removes all inner faces amd make solid from compsolid
59 ----------------------------------------------
61 ----------------------------------------------
63 Create(S : Shell from TopoDS)
64 ---Purpose: Make a solid from a shell.
66 returns MakeSolid from BRepBuilderAPI;
69 Create(S1,S2 : Shell from TopoDS)
70 ---Purpose: Make a solid from two shells.
72 returns MakeSolid from BRepBuilderAPI;
74 Create(S1,S2,S3 : Shell from TopoDS)
75 ---Purpose: Make a solid from three shells.
77 returns MakeSolid from BRepBuilderAPI;
79 ---Purpose: Constructs a solid
80 -- - covering the whole space, or
82 -- - from two shells S1 and S2, or
83 -- - from three shells S1, S2 and S3, or
85 -- No check is done to verify the conditions of coherence
86 -- of the resulting solid. In particular, S1, S2 (and S3) must
87 -- not intersect each other.
88 -- Besides, after all shells have been added using the Add
89 -- function, one of these shells should constitute the outside
90 -- skin of the solid; it may be closed (a finite solid) or open
91 -- (an infinite solid). Other shells form hollows (cavities) in
92 -- these previous ones. Each must bound a closed volume.
94 ----------------------------------------------
95 -- From solid and shells
96 ----------------------------------------------
98 Create(So : Solid from TopoDS)
99 ---Purpose: Make a solid from a solid. Usefull for adding later.
101 returns MakeSolid from BRepBuilderAPI;
103 Create(So : Solid from TopoDS; S : Shell from TopoDS)
104 ---Purpose: Add a shell to a solid.
106 returns MakeSolid from BRepBuilderAPI;
109 -- Constructs a solid:
110 -- - from the solid So, to which shells can be added, or
111 -- - by adding the shell S to the solid So.
113 -- No check is done to verify the conditions of coherence
114 -- of the resulting solid. In particular S must not intersect the solid S0.
115 -- Besides, after all shells have been added using the Add
116 -- function, one of these shells should constitute the outside
117 -- skin of the solid. It may be closed (a finite solid) or open
118 -- (an infinite solid). Other shells form hollows (cavities) in
119 -- the previous ones. Each must bound a closed volume.
121 ----------------------------------------------
123 ----------------------------------------------
125 Add(me : in out; S : Shell from TopoDS)
126 ---Purpose: Adds the shell to the current solid.
128 -- No check is done to verify the conditions of coherence
129 -- of the resulting solid. In particular, S must not intersect
130 -- other shells of the solid under construction.
131 -- Besides, after all shells have been added, one of
132 -- these shells should constitute the outside skin of the
133 -- solid. It may be closed (a finite solid) or open (an
134 -- infinite solid). Other shells form hollows (cavities) in
135 -- these previous ones. Each must bound a closed volume.
138 ----------------------------------------------
140 ----------------------------------------------
142 IsDone(me) returns Boolean
143 ---Purpose: Returns true if the solid is built.
144 -- For this class, a solid under construction is always valid.
145 -- If no shell has been added, it could be a whole-space
146 -- solid. However, no check was done to verify the
147 -- conditions of coherence of the resulting solid.
150 Solid(me) returns Solid from TopoDS
151 ---Purpose: Returns the new Solid.
153 ---C++: return const &
154 ---C++: alias "Standard_EXPORT operator TopoDS_Solid() const;"
160 IsDeleted (me: in out; S : Shape from TopoDS)
166 myMakeSolid : MakeSolid from BRepLib;