C3D Toolkit
Kernel - 117982, Vision - 2.9.2.2
|
Apex (point). More...
#include <mesh_primitive.h>
Public Member Functions | |
MbApex3D () | |
Constructor without parameters. | |
virtual | ~MbApex3D () |
Destructor. | |
MbePrimitiveType | Type () const override |
Get the object type. | |
void | AddYourGabaritTo (MbCube &) const override |
Extend given bounding box so that it encloses the given object. | |
double | DistanceToPoint (const MbCartPoint3D &) const override |
Calculate distance to point. | |
double | DistanceToLine (const MbAxis3D &, double extDistance, double &t) const override |
Calculate the distance to the axis. | |
Functions of the apex. | |
virtual void | Init (const MbCartPoint3D &)=0 |
Initialize apex by a point. | |
virtual void | Init (const MbFloatPoint3D &)=0 |
Initialize apex by a point. | |
virtual void | GetPoint (MbCartPoint3D &) const =0 |
Initialize point by an apex. | |
virtual void | GetPoint (MbFloatPoint3D &) const =0 |
Initialize point by an apex. | |
virtual bool | IsSame (const MbApex3D &, double eps) const =0 |
Determine whether objects are equal. | |
virtual void | Init (const MbApex3D &)=0 |
Init by other apex. | |
![]() | |
virtual | ~MbPrimitive () |
Destructor. | |
virtual MbePrimitiveType | IsA () const =0 |
MbeRefType | RefType () const override |
Registration type (for copying, duplication). | |
virtual MbPrimitive & | Duplicate (MbRegDuplicate *iReg=nullptr) const |
Create a copy of primitive. More... | |
virtual SPtr< MbPrimitive > | Clone (MbRegDuplicate *iReg=nullptr) const =0 |
Create a copy of primitive. More... | |
virtual void | Transform (const MbMatrix3D &matr)=0 |
Transform primitive according to the matrix. More... | |
virtual void | Move (const MbVector3D &to)=0 |
Move primitive along a vector. More... | |
virtual void | Rotate (const MbAxis3D &axis, double angle)=0 |
Rotate primitive about an axis by a given angle. More... | |
MbeImplicationType | ImplicationType () const override |
Get attribute container type. | |
virtual void | GetProperties (MbProperties &)=0 |
Get properties of the object. | |
virtual void | SetProperties (const MbProperties &)=0 |
Set properties of the object. | |
SimpleName | GetPrimitiveName () const |
void | SetPrimitiveName (SimpleName n) |
const MbName & | GetName () const |
Get name of object. | |
MbName & | SetName () |
Get name of object for modification. | |
SimpleName | GetFirstName () const |
Get first name. | |
SimpleName | GetNameHash () const |
Get hash of name. | |
void | SetName (const MbName &n) |
Set name. | |
const MbRefItem * | GetItem () const |
Get begetter object of primitive. | |
void | SetItem (const MbRefItem *g) |
Set begetter object of primitive. | |
MbeRefType | GetPrimitiveType () const |
Get type of object. | |
void | SetPrimitiveType (MbeRefType t) |
Set type of object. | |
bool | NearestType (MbeSpaceType sType, MbeTopologyType tType, MbePlaneType pType) const |
Does the primitive satisfy the nearest object search criteria? | |
const MbSpaceItem * | SpaceItem () const |
Get spatial object for which the primitive is constructed. | |
const MbPlaneItem * | PlaneItem () const |
Get two-dimensional object for which the primitive is constructed. | |
const MbTopItem * | TopItem () const |
Get the topological object for which the primitive is constructed. | |
const MbItem * | Item () const |
Get geometric model object for which the primitive is constructed. | |
void | PrimitiveRead (reader &) |
Reading of primitive from the stream. | |
void | PrimitiveWrite (writer &) const |
Writing of primitive to the stream. | |
![]() | |
MbAttributeContainer () | |
Constructor without parameters. | |
MbAttributeContainer (MbAttribute &) | |
Constructor by attribute. | |
virtual | ~MbAttributeContainer () |
Destructor. | |
void | AttributesRead (reader &) |
Read attributes from stream. | |
void | AttributesWrite (writer &) const |
Writing attributes to stream. | |
void | GetProperties (MbProperties &) |
Get properties of attributes. | |
void | SetProperties (const MbProperties &) |
Set properties of attributes. | |
void | SetDensity (double) |
Set density of an object. | |
double | GetDensity () const |
Get density of an object. | |
void | SetVisual (float a, float d, float sp, float sh, float t, float e, uint rgb=0) |
Set visual properties of the object. | |
void | SetVisual (const MbRGBA &ambient, const MbRGBA &diffuse, const MbRGBA &specular, const MbRGBA &emission, uint8 shininess, uint8 opacity, uint8 chrom) |
Set visual properties of the object. | |
bool | GetVisual (float &a, float &d, float &sp, float &sh, float &t, float &e, uint rgb=0) const |
Get visual properties of the object. More... | |
bool | IsColored () const |
void | SetColor (uint32) |
Change color of the object. | |
void | SetColor (int R, int G, int B) |
Change color of the object (0-255). | |
uint32 | GetColor () const |
Get color of an object. | |
void | SetWidth (int) |
Set thickness of lines for object's representation. | |
int | GetWidth () const |
Get thickness of lines for object's representation. | |
void | SetStyle (int) |
Set style of lines for object's representation. | |
int | GetStyle () const |
Get style of lines for object's representation. | |
void | SetSelected (bool s=true) |
To allocate or not to allocate an object. | |
bool | IsSelected () const |
Is the object selected. | |
bool | ReverseSelected () |
Invert object selection. | |
void | SetChanged (bool c=true) |
Set: the object is changed or isn't changed. | |
bool | IsChanged () const |
Is the object changed? | |
void | SetVisible (bool) |
Set visibility. | |
bool | IsVisible () const |
Is the object visible? | |
bool | IsInvisible () const |
Is the object invisible? | |
void | AttributesAssign (const MbAttributeContainer &) |
Duplicate attributes of a given object, release existing attributes. | |
size_t | AttributesCount () const |
Get the number of objects. | |
bool | RemoveAttributes (bool onDeleteOwner=false) |
Delete all attributes from container. | |
MbAttribute * | AddAttribute (MbAttribute *attr, bool checkSame=true) |
Add attribute in container. More... | |
MbAttribute * | AddAttribute (const MbAttribute &attr, bool checkSame=true) |
Add attribute in container (adds a copy of the attribute if it can be added). More... | |
void | GetAttributes (c3d::AttrVector &attrs, MbeAttributeType aFamily, MbeAttributeType subType) const |
Get attributes of a given type or family. More... | |
void | GetAttributes (c3d::AttrVector &attrs, MbeAttributeType aType) const |
Get attributes of a given type. More... | |
template<class AttrVector > | |
void | GetAttributes (AttrVector &attrs) const |
Get attributes. More... | |
void | GetCommonAttributes (c3d::AttrVector &, const c3d::string_t &samplePrompt, MbeAttributeType subType=at_Undefined, bool firstFound=false) const |
Get attributes using sample of description string. | |
void | GetStringAttributes (c3d::AttrVector &, const c3d::string_t &sampleContent) const |
Get string attributes using sample of contents of the string. | |
bool | RemoveAttribute (const MbAttribute *, bool checkAccuracySame=false, double accuracy=LENGTH_EPSILON) |
Get an attribute of a given type, the first one is returned if there are many. More... | |
bool | RemoveAttributes (MbeAttributeType type, MbeAttributeType subType) |
Delete attributes of a given type. | |
const MbAttribute * | GetSimpleAttribute (MbeAttributeType) const |
Get a simple attribute of a given subtype. | |
MbAttribute * | SetSimpleAttribute (MbeAttributeType) |
Get a simple attribute of a given subtype. | |
MbAttribute * | SetSimpleAttribute (MbAttribute *simpAttr) |
Set a simple attribute of a given subtype. | |
MbAttribute * | SetSimpleAttribute (const MbAttribute &simpAttr) |
Set a simple attribute of a given subtype (always copies the attribute). | |
void | RemoveSimpleAttribute (MbeAttributeType) |
Delete simple attributes (one or more) of a given subtype. | |
MbAttribute * | DetachSimpleAttribute (MbeAttributeType) |
Detach a simple attribute of a given subtype. | |
void | GetUserAttributes (std::vector< MbUserAttribute * > &attrs, const MbUserAttribType &type) const |
Get a user attribute of a given subtype. | |
void | RemoveUserAttributes (const MbUserAttribType &type) |
Delete user attributes (one or more) of a given subtype. | |
void | DetachUserAttributes (std::vector< MbUserAttribute * > &attrs, const MbUserAttribType &type) |
Detach a user attribute of a given subtype. | |
void | AttributesChange () |
Perform actions when changing the attributes. | |
void | AttributesConvert (MbAttributeContainer &other) const |
Perform actions when converting the attributes. | |
void | AttributesTransform (const MbMatrix3D &, MbRegTransform *=nullptr) |
Perform actions when transforming the attributes. | |
void | AttributesMove (const MbVector3D &, MbRegTransform *=nullptr) |
Perform actions when moving the attributes. | |
void | AttributesRotate (const MbAxis3D &, double angle, MbRegTransform *=nullptr) |
Perform actions when rotating the attributes. | |
void | AttributesCopy (MbAttributeContainer &other, MbRegDuplicate *=nullptr) const |
Perform actions when copying the attributes. | |
void | AttributesMerge (MbAttributeContainer &other) |
Perform actions when merging the attributes. | |
void | AttributesReplace (MbAttributeContainer &other) |
Perform actions when replacing the attributes. | |
void | AttributesSplit (const std::vector< MbAttributeContainer * > &others) |
Perform actions when splitting the attributes. | |
void | AttributesDelete () |
Perform actions when deleting the attributes. | |
![]() | |
refcount_t | GetUseCount () const |
Get count of references (get count of owners of an object). | |
refcount_t | AddRef () const |
Increase count of references by one. | |
refcount_t | DecRef () const |
Decrease count of references by one. | |
refcount_t | Release () const |
Decrease count of references by one and if count of references became zero, then remove itself. | |
![]() | |
void | Lock () const |
Switch lock on (locking happens only in parallel region). | |
void | Unlock () const |
Switch lock off if locking has been set. | |
CommonRecursiveMutex * | GetLock () const |
Get a pointer to the mutex object. Return nullptr if no parallelism. For use in ScopedLock. | |
Protected Member Functions | |
MbApex3D (const MbApex3D &, MbRegDuplicate *) | |
Copy-constructor with the registrator. | |
![]() | |
MbPrimitive (const MbPrimitive &, MbRegDuplicate *iReg) | |
Copy-constructor with the registrator. | |
MbPrimitive () | |
Constructor without parameters. | |
![]() | |
MbAttributeContainer (const MbAttributeContainer &, MbRegDuplicate *) | |
Copy-constructor with the registrator. | |
![]() | |
MbRefItem () | |
Constructor without parameters. | |
Additional Inherited Members | |
![]() | |
static MbUserAttribute * | ReduceUserAttrib (const MbExternalAttribute &) |
Convert user attribute to "system" one. | |
static MbExternalAttribute * | AdvanceUserAttrib (const MbUserAttribute &) |
Convert "system" attribute to user one. | |
![]() | |
MbName | name |
Name of primitive. | |
const MbRefItem * | parentItem |
Begetter object (don't own). | |
MbeRefType | type |
Type of primitive. | |
Apex (point).
Apex defines position of a point, of a vertex or the other point-object in space.