Constructing a Body by Thickening the Surface

The function

MbResultType ThinSolid( const MbSurface &       surface,
                              bool              faceSense,
                              SweptValues &     params,
                        const MbSNameMaker &    names,
                              SimpleName        name,
                              MbSolid *&        result )

constructs a body by thickening the given surface.

The input parameters of the function are:

  • solid — the given surface;

  • faceSense — orientation of the normal of the face constructed on the surface;

  • params — an object containing construction parameters;

  • names — the operation namer;

  • name — the operation name.

The output parameter of the function is the constructed body result.

The function returns an operation result code from the MbResultType enumeration.

The function is declared in the file action_solid.h.

The function constructs a face based on the surface surface and then builds a body by assigning the specified thickness to this face.

The faceSense parameter indicates whether the direction of the surface normal matches the direction of the face normal (true if they match, false otherwise). The face will be assigned the thickness specified in the params parameter.

The params parameter contains information about the wall thickness of the constructed body result. The wall thickness can be either params.thickness1 in the positive direction of the face normal or params.thickness2 in the negative direction of the face normal.

The names and name parameters provide naming for the faces, edges, and vertices of the constructed body.

Figure 1 shows the source surface surface:

../../../../_images/M.2.15.1.png

Fig. 1

Figure 2 shows the constructed body result:

../../../../_images/M.2.15.2.png

Fig. 2

The ThinSolid() function adds to the construction log of the constructed body a builder MbShellSolid that contains all the necessary data for performing the operation. The MbShellSolid builder is declared in the file cr_thin_shell_solid.h.

In the test application test.exe, construction of a thin-walled body is performed by the menu command “Create → Solid → Based on a surface → By thickening”.