MbSolid Solid Body

The MbSolid class is declared in the solid.h file.

A solid body, or simply a body, MbSolid is derived from the MbItem class and is described by a set of faces MbFaceShell outer and the connectivity type multiState.

A body is a set of faces joined to each other along edges and describing the surface of the modeled object. A body may describe one or several connected sets of points. The connectivity type multiState indicates whether the body describes a single connected set of points or whether the body describes several connected sets of points and can be split into several bodies.

The set of faces outer of a body, depending on the presence of boundary edges, may describe two fundamentally different sets of points. If the set of faces has no boundary, then the body describes the set of points lying on the surfaces of the faces and on the inner side of these faces. Such a body is called closed and is described by a closed shell. A closed body is shown in Fig. 1.

../../../../_images/O.8.2.1.png

Fig. 1

If the set of faces of a body has a boundary or boundaries, then the body describes a set of points lying only on the surfaces of the faces. Such a body is called open and is described by an open shell. An open body is shown in Fig. 2.

../../../../_images/O.8.2.2.png

Fig. 2

In most cases, a closed body is described by a single connected set of faces, that is, by a single shell. If a closed body has internal cavities, the body is described by several connected sets of faces. Fig. 3 shows a closed body described by two closed shells, one outer and one inner, located inside the outer shell.

../../../../_images/O.8.2.3.png

Fig. 3

To make the cavity of the body visible, the body is rendered semi-transparent.

Various operations can be performed on bodies – a set of actions resulting in a body of a different shape, for example, Boolean operations. The result of subtracting two closed bodies is shown in Fig. 4.

../../../../_images/O.8.2.4.png

Fig. 4

The result of an operation on a closed and an open body is fundamentally different, because the actions are performed on different sets of points. The result of subtracting a body from an open body is shown in Fig. 5.

../../../../_images/O.8.2.5.png

Fig. 5

A body may be multiply connected, that is, it may consist of several separate parts. In this case, multiState takes the value ms_Multiple. A doubly connected body described by two closed shells is shown in Fig. 6.

../../../../_images/O.8.2.6.png

Fig. 6

Such a body can be divided into two simply connected closed bodies by the DetachParts() method. The body in Fig. 6 is rendered semi-transparent. A doubly connected body described by two open shells is shown in Fig. 7.

../../../../_images/O.8.2.7.png

Fig. 7

Such a body can be divided into two simply connected open bodies.

Bodies are created by methods of the C3D geometric kernel. Simple-shaped bodies are created from points, curves, and surfaces. Using operations, more complex bodies can be obtained from simple-shaped bodies. The original bodies can be edited and similar bodies can be created by changing the parameters of the MbTransactions construction journal or by directly modifying the elements of already constructed bodies. Open bodies are used in surface modeling. An open body makes it possible to focus efforts on complex shapes of the modeled object.