C3D Toolkit  Kernel - 117982, Vision - 2.9.2.2
+ Collaboration diagram for Direct Solid Modeling:

Functions

MbResultType TransformedSolid (MbSolid &solid, MbeCopyMode sameShell, const TransformValues &p, const MbSNameMaker &names, MbSolid *&result)
 Modify a solid by the matrix. More...
 
bool CollectFacesForModification (const MbFaceShell &shell, const MbCollectFacesParams &parameters, c3d::FacesVector &outputFaces)
 Collect faces for direct modeling methods. More...
 
MbResultType CollectFacesForModification (MbFaceShell *shell, MbeModifyingType way, double radius, RPArray< MbFace > &faces)
 Modify a shell by the methods of direct modeling. More...
 
MbResultType ModifiedSolid (MbSolid &solid, MbeCopyMode sameShell, const MbModifiedSolidParams &params, MbModifiedSolidResults &results)
 Modify a solid by the methods of direct modeling. More...
 
MbResultType FaceModifiedSolid (MbSolid &solid, MbeCopyMode sameShell, const ModifyValues &params, const RPArray< MbFace > &faces, const MbSNameMaker &names, MbSolid *&result)
 Modify a solid by the methods of direct modeling. More...
 
MbResultType EdgeModifiedSolid (MbSolid &solid, MbeCopyMode sameShell, const ModifyValues &params, const RPArray< MbCurveEdge > &edges, const MbSNameMaker &names, MbSolid *&result)
 Modify a solid by the methods of direct modeling. More...
 
MbResultType ModifiedNurbsItem (MbSolid &solid, MbeCopyMode sameShell, const NurbsValues &p, const RPArray< MbFace > &faces, const MbSNameMaker &names, MbSolid *&result)
 Replace the specified faces of solid with deformable faces. More...
 
MbResultType ModifiedNurbsItem (MbSolid &solid, MbeCopyMode sameShell, const NurbsValues &p, const MbFace &face, const MbSNameMaker &names, MbSolid *&result)
 Replace the specified face of the solid by a deformable face. More...
 
MbSurfaceGetControlSurface (const MbFace &face)
 Get the NURBS-surfaces of a face. More...
 
MbResultType FaceControlPoints (const MbFace &face, Array2< MbCartPoint3D > &controlPoints, Array2< double > &result)
 Get the control points of the NURBS-surface of a face. More...
 
MbResultType NurbsModification (MbSolid &solid, MbeCopyMode sameShell, MbFace *face, MbSurface &faceSurface, Array2< bool > &fixedPoints, const MbSNameMaker &names, MbSolid *&result)
 Deform a face of a solid. More...
 
MbResultType NurbsModification (MbSolid &solid, MbeCopyMode sameShell, MbFace *face, const Array2< MbCartPoint3D > &controlPoints, const Array2< double > &weights, Array2< bool > *fixedPoints, const MbSNameMaker &names, MbSolid *&result)
 Deform a face of a solid. More...
 
MbResultType NurbsBlockSolid (const MbPlacement3D &place, double ax, double ay, double az, bool outDir, const MbSNameMaker &names, SimpleName name, NurbsBlockValues &param, MbSolid *&result)
 Create a deformable prism. More...
 
MbResultType NurbsFaceConjugation (const MbSurfaceIntersectionCurve &curve, bool sences, bool faceSences, const MbSplineSurface &surface, double tension, MbeConjugationType conType, size_t insertNum, MbSplineSurface *&result)
 Create a matched surface. More...
 
MbResultType NurbsFaceSimilarity (const MbSurface &originSurface, const MbSplineSurface &surface, bool uToU, bool normSence, MbSplineSurface *&result)
 Create a similar surface. More...
 
MbResultType SplineSurfaceSmoothing (const MbSplineSurface &surface, size_t udegree, size_t vdegree, MbSplineSurface *&result)
 Create a smoothed surface. More...
 

Detailed Description

Function Documentation

◆ TransformedSolid()

MbResultType TransformedSolid ( MbSolid solid,
MbeCopyMode  sameShell,
const TransformValues p,
const MbSNameMaker names,
MbSolid *&  result 
)

Modify a solid by the matrix.

Transform a copy of the solid using the matrix calculated by bounding box of solid.

Parameters
[in]solid- The initial solid.
[in]sameShell- The mode of copying of the initial solid.
[in]p- The transformation parameters.
[in]names- An object for naming the new objects.
[out]result- The modified solid.
Returns
Returns operation result code.

◆ CollectFacesForModification() [1/2]

bool CollectFacesForModification ( const MbFaceShell shell,
const MbCollectFacesParams parameters,
c3d::FacesVector &  outputFaces 
)

Collect faces for direct modeling methods.

The main purpose of this function is to highlight faces that will be modified. The method collects the faces of the shell for direct modeling methods:
dmm_RemoveBelowRadius, dmm_RemoveBelowRadiusWithAdjacentFillets, dmm_PurifyFilletsBelowRadius, dmm_FilletsRadiusSet, dmm_FilletsRadiusSetSingle, dmm_FilletsRadiusChange.
The cylindrical, conical, toroidal, spherical, and revolution periodic faces are collected for the dmm_RemoveBelowRadius type. The cylindrical, toroidal, spherical non-periodic, and fillet faces are collected for the dmm_PurifyFilletsBelowRadius type.

Parameters
[in]shell- The initial shell.
[in]parameters- The operation parameters.
[out]outputFaces- Found faces to be modified.
Returns
Returns action result code.

◆ CollectFacesForModification() [2/2]

MbResultType CollectFacesForModification ( MbFaceShell shell,
MbeModifyingType  way,
double  radius,
RPArray< MbFace > &  faces 
)

Modify a shell by the methods of direct modeling.

The method collects the faces of the shell for direct modeling methods:
removal of the faces from a shell (way==dmt_Remove),
removal of the fillet faces from a shell (way==dmt_Purify).
The cylindrical, conical, toroidal, spherical, and revolution periodic faces are collect to remove way. The cylindrical, toroidal, spherical non-periodic, and fillet faces are collect to purify way.

Deprecated:
The method is deprecated. Use instead CollectFacesForModification with the parameters MbCollectFacesParams.
Parameters
[in]shell- The initial faces set.
[in]way- Way of the modification.
[in]radius- Radius of collected faces.
[in]faces- Found faces to be modified.
Returns
Returns action result code.

◆ ModifiedSolid()

MbResultType ModifiedSolid ( MbSolid solid,
MbeCopyMode  sameShell,
const MbModifiedSolidParams params,
MbModifiedSolidResults results 
)

Modify a solid by the methods of direct modeling.

The method performs one of the following actions depending on the parameter MbModifiedSolidParams:

  1. Removal of the specified faces without the adjacent fillets (dmm_RemoveFaces).
    Removal of the specified faces with the adjacent fillets (dmm_RemoveFacesWithAdjacentFillets). Removal of the close cylindric, spherical faces, extrusion and rotation faces below specified radius with the adjacent fillets (dmm_RemoveBelowRadiusWithAdjacentFillets).
    Removal of the close cylindric, spherical faces, extrusion and rotation faces below specified radius without the adjacent fillets (dmm_RemoveBelowRadius).
  2. Creation of a solid from the specified faces with the neighborhood (dmm_Create).
  3. Translation of the specified faces with neighborhood relative to the other faces of the solid (dmm_MoveFacesByVector). The translation direction is defined by the 'direction' vector.
  4. Replacement of the specified faces by offset faces (dmm_OffsetFaces). The distance of the offset (or radius change) is defined by 'value'.
  5. Radius change of the specified fillet faces (dmm_FilletChange). The value of radius change is defined by 'value'.
  6. Replacement of the specified faces of a solid with a deformable NURBS faces for editing (dmm_ConvertFacesToNurbs).
  7. Remove of the specified fillet faces from a solid (dmm_PurifyFillets). Remove of the specified fillet faces with all smoothly connected fillets (dmm_PurifyFilletsChains). Remove of all fillets below specified radius from a solid (dmm_PurifyFilletsBelowRadius).
  8. Edge vertices merging and edges removal (dmm_DeleteEdges).
  9. Replacement of the smoothly joined faces with a single face (dmm_UniteFaces).
  10. Rotation of the chosen faces with the adjacent fillets adaptation (dmm_RotateFaces) or without (dmm_RotateFacesNoFilletAdaptation ). The parameters are the rotation angle and the rotation axis.
  11. Replacement of the specified faces of a solid (dmm_ReplaceFaces).
    The function simultaneously creates the shell and its constructor.
    Parameters
    [in]solid- The initial solid.
    [in]sameShell- The mode of copying of the initial solid.
    [in]params- Parameters of the modification.
    [out]results- Results of the modifcation.
    Returns
    Returns operation result code.

◆ FaceModifiedSolid()

MbResultType FaceModifiedSolid ( MbSolid solid,
MbeCopyMode  sameShell,
const ModifyValues params,
const RPArray< MbFace > &  faces,
const MbSNameMaker names,
MbSolid *&  result 
)

Modify a solid by the methods of direct modeling.

Deprecated:
The method is deprecated and will be removed in version 2024.

The method performs one of the following actions depending on the parameter ModifyValues:

  1. Removal of the specified faces with the neighborhood from a solid (param.way==dmt_Remove).
  2. Creation of a solid from the specified faces with the neighborhood (param.way==dmt_Create).
  3. Translation of the specified faces with neighborhood relative to the other faces of the solid (param.way==dmt_Action).
  4. Replacement of the specified faces by offset faces (param.way==dmt_Offset).
  5. Radius change of the specified fillet faces (param.way==dmt_Fillet).
  6. Replacement of the specified faces of a solid with a deformable faces for editing (param.way==dmt_Supple).
  7. Removal of the specified fillet faces from a solid (param.way==dmt_Purify).
  8. Replacement of the smoothly joined faces with a single face (param.way==dmt_United).
  9. Rotation of the chosen faces (param.way==dmt_Rotate).
    Parameters
    [in]solid- The initial solid.
    [in]sameShell- The mode of copying of the initial solid.
    [in]params- Parameters of the modification.
    [in]faces- Faces to be modified.
    [in]names- An object for naming the new objects.
    [out]result- The modified solid.
    Returns
    Returns operation result code.

◆ EdgeModifiedSolid()

MbResultType EdgeModifiedSolid ( MbSolid solid,
MbeCopyMode  sameShell,
const ModifyValues params,
const RPArray< MbCurveEdge > &  edges,
const MbSNameMaker names,
MbSolid *&  result 
)

Modify a solid by the methods of direct modeling.

Deprecated:
The method is deprecated and will be removed in version 2024.

The method performs the deletion of selectsd edges, merging their vertices and modification of surrounding faces (param.way==dmt_Merger). The direction of the vector "params.direction" determines whether the start vertex of an edge is merged with the end vertex, or whether the end vertex of an edge is merged with the start vertex.

Parameters
[in]solid- The initial solid.
[in]sameShell- The mode of copying of the initial solid.
[in]params- Parameters of the modification, the way must be equal to param.way==dmt_Merger.
[in]edges- Edges to be removed.
[in]names- An object for naming the new objects.
[out]result- The modified solid.
Returns
Returns operation result code.

◆ ModifiedNurbsItem() [1/2]

MbResultType ModifiedNurbsItem ( MbSolid solid,
MbeCopyMode  sameShell,
const NurbsValues p,
const RPArray< MbFace > &  faces,
const MbSNameMaker names,
MbSolid *&  result 
)

Replace the specified faces of solid with deformable faces.

Replace the specified faces of the solid with deformable faces (conversion to NURBS for editing).

Parameters
[in]solid- The initial solid.
[in]sameShell- The mode of copying of the initial solid.
[in]p- The transformation parameters.
[in]faces- Faces to replace.
[in]names- An object for naming the new objects.
[out]result- The modified solid.
Returns
Returns operation result code.

◆ ModifiedNurbsItem() [2/2]

MbResultType ModifiedNurbsItem ( MbSolid solid,
MbeCopyMode  sameShell,
const NurbsValues p,
const MbFace face,
const MbSNameMaker names,
MbSolid *&  result 
)

Replace the specified face of the solid by a deformable face.

Replace the specified face of the solid by a deformable face (conversion to NURBS for editing).

Parameters
[in]solid- The initial solid.
[in]sameShell- The mode of copying of the initial solid.
[in]p- The transformation parameters.
[in]face- A face to replace.
[in]names- An object for naming the new objects.
[out]result- The modified solid.
Returns
Returns operation result code.

◆ GetControlSurface()

MbSurface* GetControlSurface ( const MbFace face)

Get the NURBS-surfaces of a face.

Create a deformable surface for the initial face.

Parameters
[in]face- The initial face.
Returns
Returns NURBS-surfaces of the face.

◆ FaceControlPoints()

MbResultType FaceControlPoints ( const MbFace face,
Array2< MbCartPoint3D > &  controlPoints,
Array2< double > &  result 
)

Get the control points of the NURBS-surface of a face.

Get a set of the control points of a NURBS-surface of a face and a set of their weights.

Parameters
[in]face- The initial face.
[out]controlPoints- The control points of the NURBS-surface of the face.
[out]result- The weights of the control points.
Returns
Returns operation result code.

◆ NurbsModification() [1/2]

MbResultType NurbsModification ( MbSolid solid,
MbeCopyMode  sameShell,
MbFace face,
MbSurface faceSurface,
Array2< bool > &  fixedPoints,
const MbSNameMaker names,
MbSolid *&  result 
)

Deform a face of a solid.

Deform a face of a solid by substitution the control points of NURBS-surface of the face with the given control points.

Parameters
[in]solid- The initial solid.
[in]sameShell- The mode of copying of the initial solid.
[in]face- A face of a solid to be modified.
[in]faceSurface- The new NURBS-surface of the face.
[in]fixedPoints- The fixed points.
[in]names- An object for naming the new objects.
[out]result- The modified solid.
Returns
Returns operation result code.

◆ NurbsModification() [2/2]

MbResultType NurbsModification ( MbSolid solid,
MbeCopyMode  sameShell,
MbFace face,
const Array2< MbCartPoint3D > &  controlPoints,
const Array2< double > &  weights,
Array2< bool > *  fixedPoints,
const MbSNameMaker names,
MbSolid *&  result 
)

Deform a face of a solid.

Deform a face of a solid by substitution the control points of NURBS-surface of the face with the given control points.

Parameters
[in]solid- The initial solid.
[in]sameShell- The mode of copying of the initial solid.
[in]face- A face of a solid to be modified.
[in]controlPoints- The control points of the NURBS-surface of the face.
[in]weights- The weights of the control points.
[in]fixedPoints- The fixed points.
[in]names- An object for naming the new objects.
[out]result- The modified solid.
Returns
Returns operation result code.

◆ NurbsBlockSolid()

MbResultType NurbsBlockSolid ( const MbPlacement3D place,
double  ax,
double  ay,
double  az,
bool  outDir,
const MbSNameMaker names,
SimpleName  name,
NurbsBlockValues param,
MbSolid *&  result 
)

Create a deformable prism.

Create a solid as a right parallelepiped with deformable faces.

Parameters
[in]place- A local coordinate system.
[in]ax- The size in X-direction.
[in]ay- The size in Y-direction.
[in]az- The size in Z-direction.
[in]outDir- An outer orientation of the normals.
[in]names- An object for naming the new objects.
[in]name- The main name.
[in]param- The parameters of NURBS-surfaces of the parallelepiped faces.
[out]result- The solid constructed from the NU|RBS-surfaces.
Returns
Returns operation result code.

◆ NurbsFaceConjugation()

MbResultType NurbsFaceConjugation ( const MbSurfaceIntersectionCurve curve,
bool  sences,
bool  faceSences,
const MbSplineSurface surface,
double  tension,
MbeConjugationType  conType,
size_t  insertNum,
MbSplineSurface *&  result 
)

Create a matched surface.

Create a modified surface for the initial surface by specifying the conjugation along the curve.

Parameters
[in]curve- The intersection curve of the edge surfaces.
[in]sences- The edge curve sense in the loop.
[in]faceSences- The adjacent face normal orientation.
[in]surface- The initial spline surface of the face to be modified.
[in]tension- The tension.
[in]conType- The conjugation type.
[in]insertNum- The row number.
[out]result- The NURBS-surface obtained as a result of the modifications.
Returns
Returns operation result code.

◆ NurbsFaceSimilarity()

MbResultType NurbsFaceSimilarity ( const MbSurface originSurface,
const MbSplineSurface surface,
bool  uToU,
bool  normSence,
MbSplineSurface *&  result 
)

Create a similar surface.

Create a surface similar to the initial one given the pattern surface.

Parameters
[in]originSurface- A pattern surface.
[in]surface- The initial spline surface of the face to be modified.
[in]uToU- Whether to keep the parametric direction of the pattern surface.
[in]normSence- Whether to keep the normal direction of the pattern surface.
[out]result- The NURBS-surface obtained as a result of the modifications.
Returns
Returns operation result code.

◆ SplineSurfaceSmoothing()

MbResultType SplineSurfaceSmoothing ( const MbSplineSurface surface,
size_t  udegree,
size_t  vdegree,
MbSplineSurface *&  result 
)

Create a smoothed surface.

Perform smoothing of a copy of the initial surface without changing its order and the number of control points.

Parameters
[in]surface- The initial spline surface of the face to be modified.
[in]udegree- The smoothing surface degree for direction of first parameter of surface.
[in]vdegree- The smoothing surface degree for direction of second parameter of surface.
[out]result- The NURBS-surface obtained as a result of the modifications.
Returns
Returns operation result code.