MbFace Face

The MbFace class is declared in the topology.h file.

The MbFace face is a derived class of the MbTopologyItem topological object and represents a finite portion of a surface with an assigned normal direction and defined boundaries. The side of a surface and of a face that we see when looking along the normal direction is called the outer side, and the other side is called the inner side. The sides of the MbSurface surface are not equivalent with respect to the normal, because one side of the surface is always outer and the other side is always inner. In contrast to a surface, for a face we can assign the normal direction and thereby define outer and inner sides.

The face data structure contains a pointer to the surface MbSurface surface, a flag indicating coincidence of the face normal direction with the surface normal direction sameSense, and a set of face loops RPArray<MbLoop> loops. A face also has some additional data that is not mandatory and is used to speed up execution of face methods.

The surface pointer cannot be null. The flag indicating coincidence of the face normal direction with the surface normal direction is set to true if the face and surface normals coincide; otherwise, the flag is set to false. The side of the face that we see when looking along the normal direction is called the outer side, and the other side of the face is called the inner side.

Face loops define the boundaries of the face. Each face boundary is closed. Each loop is defined by a sequence of MbOrientedEdge edges following one another along the boundary. The number of face loops equals the number of boundaries of the face surface. One of the face boundaries is outer and contains the boundaries of inner holes. The loop that appears first in the loop container describes the outer boundary of the face and contains inside it inner loops that describe inner boundaries of the face. The outer loop of the face is oriented counterclockwise, and inner loops are oriented clockwise when viewed along the face normal. Thus, when moving along a face loop on its outer side, the face always lies to the left. In Fig. 1, arrows indicate the directions of the face loops and its normal.

../../../../_images/O.7.2.1.png

Fig. 1

Loops of a single face must not intersect one another or themselves.

A face can be named and can have attributes. The name can be used to identify the face, and attributes can carry additional information about the face, such as color, transparency, origin, and so on.

A face is used for solid and hybrid modeling.