C3D Toolkit  Kernel - 117982, Vision - 2.9.2.2
+ Collaboration diagram for Geometric Model Objects:

Classes

class  MbAssembly
 Assembly unit. More...
 
class  MbAssistingItem
 Assisting item of the geometric model. More...
 
class  MbCollection
 Collection of elements. More...
 
class  MtGeomArgument
 An argument of geometric constraint. More...
 
class  MtGeomConstraint
 Geometric constraint. More...
 
class  MbInstance
 Instance of object. More...
 
class  MbMesh
 The polygonal geometric object - Mesh. More...
 
class  MbItem
 A model geometric object. More...
 
class  MbPlaneInstance
 Instance of a two-dimensional sketch objects. More...
 
class  MbPointFrame
 Point-frame. More...
 
class  MbSolid
 Solid solid. More...
 
class  MbSpaceInstance
 Instance of three-dimensional object. More...
 
class  MbShellsDistanceData
 The data of the minimum distance between two shells. More...
 
class  MbWireFrame
 Three-dimensional wire frame. More...
 

Functions

virtual void MbModel::GetItems (MbeSpaceType type, std::vector< SPtr< MbItem >> &items, std::vector< MbMatrix3D > &matrs)
 Get all objects by the type. More...
 
virtual void MbModel::GetItems (MbeSpaceType type, RPArray< MbItem > &items, SArray< MbMatrix3D > &matrs)
 Get all objects by type. More...
 
virtual void MbModel::GetItems (MbeSpaceType type, RPArray< const MbItem > &items, SArray< MbMatrix3D > &matrs) const
 Get all objects by type. More...
 
virtual void MbModel::GetUniqItems (MbeSpaceType type, CSSArray< const MbItem * > &items) const
 Get all unique objects by type. More...
 

Common functions of object of geometric model.

Build polygonal copy mesh.

Build a polygonal copy of the object that is represented by polygons or/and fasets.

Parameters
[in]stepData- Data for еру step calculation for polygonal object.
[in]note- Way for polygonal object constructing.
[in,out]mesh- The builded polygonal object.
bool MbItem::RebuildItem (MbeCopyMode sameShell, RPArray< MbSpaceItem > *items, IProgressIndicator *progInd) override
 Reconstruct object according to the history tree. More...
 
virtual MbItemMbItem::CreateMesh (const MbStepData &stepData, const MbFormNote &note, MbRegDuplicate *iReg) const =0
 Create polygonal object. More...
 
virtual bool MbItem::AddYourMesh (const MbStepData &stepData, const MbFormNote &note, MbMesh &mesh) const
 Add polygonal object. More...
 
virtual MbItemMbItem::CutMesh (const MbPlacement3D &cutPlace, double distance, const MbSNameMaker *names=nullptr) const
 Cut the polygonal object by one or two parallel planes. More...
 
virtual bool MbItem::NearestMesh (MbeSpaceType sType, MbeTopologyType tType, MbePlaneType pType, const MbAxis3D &axis, double maxDistance, bool gridPriority, double &t, double &dMin, MbItem *&find, SimpleName &findName, MbRefItem *&element, SimpleName &elementName, MbPath &path, MbMatrix3D &from) const
 Find the nearest object or name of the nearest object. More...
 
virtual bool MbItem::GetItems (MbeSpaceType type, const MbMatrix3D &from, std::vector< SPtr< MbItem >> &items, std::vector< MbMatrix3D > &matrs)
 Get all objects by the type. More...
 
virtual bool MbItem::GetItems (MbeSpaceType type, const MbMatrix3D &from, RPArray< MbItem > &items, SArray< MbMatrix3D > &matrs)
 Get all objects by type. More...
 
virtual bool MbItem::GetUniqItems (MbeSpaceType type, CSSArray< const MbItem * > &items) const
 Get all unique objects by type. More...
 
virtual const MbItemMbItem::GetItemByPath (const MbPath &path, size_t ind, MbMatrix3D &from, size_t currInd=0) const
 Get the object by its path. More...
 
virtual const MbItemMbItem::FindItem (const MbSpaceItem *s, MbPath &path, MbMatrix3D &from) const
 Find object by geometric object. More...
 
virtual const MbItemMbItem::FindItem (const MbPlaneItem *s, MbPath &path, MbMatrix3D &from) const
 Find object by geometric object. More...
 
virtual const MbItemMbItem::FindItem (const MbItem *s, MbPath &path, MbMatrix3D &from) const
 Find object by object of geometric model. More...
 
virtual const MbItemMbItem::GetItemByName (SimpleName n, MbPath &path, MbMatrix3D &from) const
 Find object by name. More...
 
virtual void MbItem::TransformSelected (const MbMatrix3D &matr, MbRegTransform *iReg=nullptr)
 Transform selected object according to the matrix. More...
 
virtual void MbItem::MoveSelected (const MbVector3D &to, MbRegTransform *iReg=nullptr)
 Move selected object along a vector. More...
 
virtual void MbItem::RotateSelected (const MbAxis3D &axis, double angle, MbRegTransform *iReg=nullptr)
 Rotate selected object by a given angle about an axis. More...
 
virtual bool MbItem::GetMatrixFrom (MbMatrix3D &from) const
 Get transform matrix from local coordinate system of object.
 
virtual bool MbItem::GetMatrixInto (MbMatrix3D &into) const
 Get transform matrix into local coordinate system of object.
 
void MbItem::Assign (const MbItem &other)
 Copy creators and attributes.
 
void MbItem::CopyItemName (const MbItem &other)
 Copy the name of an object.
 
SimpleName MbItem::GetItemName () const
 Get name of object.
 
void MbItem::SetItemName (SimpleName n)
 Set name of the object.
 
bool MbItem::IsAttributeEqual (int attribute)
 Whether a sign attribute matches an object?
 

Detailed Description

Function Documentation

◆ GetItems() [1/5]

virtual void MbModel::GetItems ( MbeSpaceType  type,
std::vector< SPtr< MbItem >> &  items,
std::vector< MbMatrix3D > &  matrs 
)
virtual

Get all objects by the type.

Get all objects by the type along with transformation matrices to the global coordinate system.

Parameters
[in]type- Object's type.
[out]items- Found objects.
[out]matrs- Transformation matrices of found objects to the global coordinate system.

◆ GetItems() [2/5]

virtual void MbModel::GetItems ( MbeSpaceType  type,
RPArray< MbItem > &  items,
SArray< MbMatrix3D > &  matrs 
)
virtual

Get all objects by type.

Get all objects by type and get transformation matrix to the global coordinate system.

Parameters
[in]type- Object's type.
[out]items- Found objects.
[out]matrs- Transformation matrix of found objects to the global coordinate system.

◆ GetItems() [3/5]

virtual void MbModel::GetItems ( MbeSpaceType  type,
RPArray< const MbItem > &  items,
SArray< MbMatrix3D > &  matrs 
) const
virtual

Get all objects by type.

Get all objects by type and get transformation matrix to the global coordinate system.

Parameters
[in]type- Object's type.
[out]items- Found objects.
[out]matrs- Transformation matrix of found objects to the global coordinate system.

◆ GetUniqItems() [1/2]

virtual void MbModel::GetUniqItems ( MbeSpaceType  type,
CSSArray< const MbItem * > &  items 
) const
virtual

Get all unique objects by type.

Get all unique objects by type.

Parameters
[in]type- Object's type.
[out]items- Found objects.

◆ RebuildItem()

bool MbItem::RebuildItem ( MbeCopyMode  sameShell,
RPArray< MbSpaceItem > *  items,
IProgressIndicator progInd 
)
overridevirtual

Reconstruct object according to the history tree.

Create object by the history tree.

Parameters
[in]sameShell- Whether to perform complete copying of elements while constructing.
[out]items- Container for the elements of not performed constructions (can be nullptr).
Returns
Whether an object is constructed.

Reimplemented from MbTransactions.

Reimplemented in MbWireFrame, MbPointFrame, and MbSolid.

◆ CreateMesh()

virtual MbItem* MbItem::CreateMesh ( const MbStepData stepData,
const MbFormNote note,
MbRegDuplicate iReg 
) const
pure virtual

Create polygonal object.

Create a polygonal object - a polygonal copy of the given object.

Parameters
[in]stepData- Data for step calculation during triangulation.
[in]note- Way for polygonal object constructing.
Returns
Created polygonal object.

Implemented in MbWireFrame, MbSpaceInstance, MbSolid, MbPointFrame, MbPlaneInstance, MbMesh, MbInstance, MbCollection, MbAssistingItem, and MbAssembly.

◆ AddYourMesh()

virtual bool MbItem::AddYourMesh ( const MbStepData stepData,
const MbFormNote note,
MbMesh mesh 
) const
virtual

Add polygonal object.

Add your own polygonal copy to the given polygonal object.

Parameters
[in]stepData- Data for step calculation during triangulation.
[in]note- Way for polygonal object constructing.
[out]mesh- Given polygonal object.
Returns
Whether the object is added.

Reimplemented in MbMesh, MbInstance, and MbAssembly.

◆ CutMesh()

virtual MbItem* MbItem::CutMesh ( const MbPlacement3D cutPlace,
double  distance,
const MbSNameMaker names = nullptr 
) const
virtual

Cut the polygonal object by one or two parallel planes.

Create polygonal object from a part of source polygonal object which located under XY-plane of local coordinate system at given distance.
Function 'cuts' only MbMesh polygonal object. Function 'cuts' the object by two planes: XY plane of 'place' local coordinate system and plane parallel to it and located at 'distance' distance below it. If 'distance' is less than or equal to zero, then the function "cuts" an object only by one XY plane of local coordinate system.
Contents of an object that are necessary for creation of cut object and not affected by cutting planes are added to returned cut object without copying.

Parameters
[in]cutPlace- A local coordinate system which XY plane defines a cutting plane.
[in]distance- Distance to a parallel cutting plane is measured in negative direction of Z-axis of local coordinate system.
[in]names- An object defining names generation in the operation.
Returns
Returns new polygonal object that located under XY-plane of local coordinate system at given distance.

Reimplemented in MbMesh, MbInstance, and MbAssembly.

◆ NearestMesh()

virtual bool MbItem::NearestMesh ( MbeSpaceType  sType,
MbeTopologyType  tType,
MbePlaneType  pType,
const MbAxis3D axis,
double  maxDistance,
bool  gridPriority,
double &  t,
double &  dMin,
MbItem *&  find,
SimpleName findName,
MbRefItem *&  element,
SimpleName elementName,
MbPath path,
MbMatrix3D from 
) const
virtual

Find the nearest object or name of the nearest object.

Find the nearest three-dimensional object or its name by type of object and component of the required object or its name by topological or two-dimensional type of the element (on demand) at distance from line less than or equal to the given value. Function is intended for identification of a geometric object which is begetter of a polygonal object. The real search is performed for MbMesh polygonal object's MbPrimitive elements from which the information is taken about geometric object which is begetter of the primitive.

Parameters
[in]sType- Type of required object.
[in]tType- Topological type of the required object's component.
[in]pType- Two-dimensional type of the required object's component.
[in]axis- Line of search.
[in]maxDistance- Distance from the line on which the object is looked for.
[in]gridPriority- Increased priority triangulation grid when searching.
[out]t- Parameter of found point on line.
[out]dMin- Found distance from line to an object.
[out]find- Found object.
[out]findName- Name of the found object.
[out]element- Found component of the object.
[out]elementName- Name of found component of the object.
[out]path- Object's path in the model.
[out]from- Transformation matrix of the found object to the global coordinate system.
Returns
Whether the object or its name is found.

Reimplemented in MbMesh, MbInstance, and MbAssembly.

◆ GetItems() [4/5]

virtual bool MbItem::GetItems ( MbeSpaceType  type,
const MbMatrix3D from,
std::vector< SPtr< MbItem >> &  items,
std::vector< MbMatrix3D > &  matrs 
)
virtual

Get all objects by the type.

Get all objects by the type along with transformation matrices to the global coordinate system.

Parameters
[in]type- Object's type.
[in]from- Initial transformation matrix to the global coordinate system.
[out]items- Found objects.
[out]matrs- Transformation matrices of found objects to the global coordinate system.
Returns
Whether to add this object.

Reimplemented in MbSpaceInstance, MbInstance, and MbAssembly.

◆ GetItems() [5/5]

virtual bool MbItem::GetItems ( MbeSpaceType  type,
const MbMatrix3D from,
RPArray< MbItem > &  items,
SArray< MbMatrix3D > &  matrs 
)
virtual

Get all objects by type.

Get all objects by type and get transformation matrix to the global coordinate system.

Parameters
[in]type- Object's type.
[in]from- Initial transformation matrix to the global coordinate system.
[out]items- Found objects.
[out]matrs- Transformation matrix of found objects to the global coordinate system.
Returns
Whether add this object.

Reimplemented in MbSpaceInstance, MbInstance, and MbAssembly.

◆ GetUniqItems() [2/2]

virtual bool MbItem::GetUniqItems ( MbeSpaceType  type,
CSSArray< const MbItem * > &  items 
) const
virtual

Get all unique objects by type.

Get all unique objects by type.

Parameters
[in]type- Object's type.
[out]items- Found objects.
Returns
Whether add this object.

Reimplemented in MbSpaceInstance, MbInstance, and MbAssembly.

◆ GetItemByPath()

virtual const MbItem* MbItem::GetItemByPath ( const MbPath path,
size_t  ind,
MbMatrix3D from,
size_t  currInd = 0 
) const
virtual

Get the object by its path.

Get the object by path of its position in the model and get transformation matrix of the object to the global coordinate system. Object can be contained in other object (in assembly or in instance).

Parameters
[in]path- Path of object.
[in]ind- Index of the desired object in 'path'.
[out]from- Transformation matrix of object to the global coordinate system.
[in]currInd- Index of current object in path.
Returns
Whether the path and the matrix of object are found.

Reimplemented in MbInstance, and MbAssembly.

◆ FindItem() [1/3]

virtual const MbItem* MbItem::FindItem ( const MbSpaceItem s,
MbPath path,
MbMatrix3D from 
) const
virtual

Find object by geometric object.

Find object by geometric object and also get the path to the object in model and get transformation matrix to the global coordinate system.

Parameters
[in]s- Geometric object.
[out]path- Path to object in the model.
[out]from- Transformation matrix of object to the global coordinate system.
Returns
Whether the path and the matrix of object are found.

Reimplemented in MbSpaceInstance, MbInstance, and MbAssembly.

◆ FindItem() [2/3]

virtual const MbItem* MbItem::FindItem ( const MbPlaneItem s,
MbPath path,
MbMatrix3D from 
) const
virtual

Find object by geometric object.

Find object by geometric object and also get the path to the object in model and get transformation matrix to the global coordinate system.

Parameters
[in]s- Geometric object.
[out]path- Path to object in the model.
[out]from- Transformation matrix of object to the global coordinate system.
Returns
Whether the path and the matrix of object are found.

Reimplemented in MbPlaneInstance, MbInstance, and MbAssembly.

◆ FindItem() [3/3]

virtual const MbItem* MbItem::FindItem ( const MbItem s,
MbPath path,
MbMatrix3D from 
) const
virtual

Find object by object of geometric model.

Find object by object of geometric model and also get the path to the object in model and get transformation matrix to the global coordinate system.

Parameters
[in]s- Geometric object.
[out]path- Path to object in the model.
[out]from- Transformation matrix of object to the global coordinate system.
Returns
Whether the path and the matrix of object are found.

Reimplemented in MbInstance, and MbAssembly.

◆ GetItemByName()

virtual const MbItem* MbItem::GetItemByName ( SimpleName  n,
MbPath path,
MbMatrix3D from 
) const
virtual

Find object by name.

Find object by name and also get path to object in model and get transformation matrix to the global coordinate system.

Parameters
[in]n- A name of an object.
[out]path- Path to object in the model.
[out]from- Transformation matrix of object to the global coordinate system.
Returns
Whether the path and the matrix of object are found.

Reimplemented in MbInstance, and MbAssembly.

◆ TransformSelected()

virtual void MbItem::TransformSelected ( const MbMatrix3D matr,
MbRegTransform iReg = nullptr 
)
virtual

Transform selected object according to the matrix.

Transform selected simple object according to the matrix using the registrator. If object contains other objects of geometric model then selected contents will be transformed.

Parameters
[in]matr- A transformation matrix.
[in]iReg- Registrator.

Reimplemented in MbInstance, and MbAssembly.

◆ MoveSelected()

virtual void MbItem::MoveSelected ( const MbVector3D to,
MbRegTransform iReg = nullptr 
)
virtual

Move selected object along a vector.

Move selected simple object along the vector using the registrator. If object contains other objects of geometric model then selected contents will be transformed.

Parameters
[in]to- Translation vector.
[in]iReg- Registrator.

Reimplemented in MbInstance, and MbAssembly.

◆ RotateSelected()

virtual void MbItem::RotateSelected ( const MbAxis3D axis,
double  angle,
MbRegTransform iReg = nullptr 
)
virtual

Rotate selected object by a given angle about an axis.

Rotate selected simple object about the axis by the given angle using the registrator. If object contains other objects of geometric model then selected contents will be transformed.

Parameters
[in]axis- The rotation axis.
[in]angle- The rotation angle.
[in]iReg- Registrator.

Reimplemented in MbInstance, and MbAssembly.