Open CASCADE Technology  7.3.0
Public Member Functions

BRepMesh_DataStructureOfDelaun Class Reference

Describes the data structure necessary for the mesh algorithms in two dimensions plane or on surface by meshing in UV space. More...

#include <BRepMesh_DataStructureOfDelaun.hxx>

Inheritance diagram for BRepMesh_DataStructureOfDelaun:
Inheritance graph
[legend]

Public Member Functions

 BRepMesh_DataStructureOfDelaun (const Handle< NCollection_IncAllocator > &theAllocator, const Standard_Integer theReservedNodeSize=100)
 Constructor. More...
 
API for accessing mesh nodes.
Standard_Integer NbNodes () const
 Returns number of nodes. More...
 
Standard_Integer AddNode (const BRepMesh_Vertex &theNode, const Standard_Boolean isForceAdd=Standard_False)
 Adds node to the mesh if it is not already in the mesh. More...
 
Standard_Integer IndexOf (const BRepMesh_Vertex &theNode)
 Finds the index of the given node. More...
 
const BRepMesh_VertexGetNode (const Standard_Integer theIndex)
 Get node by the index. More...
 
const BRepMesh_Vertexoperator() (const Standard_Integer theIndex)
 Alias for GetNode. More...
 
Standard_Boolean SubstituteNode (const Standard_Integer theIndex, const BRepMesh_Vertex &theNewNode)
 Substitutes the node with the given index by new one. More...
 
void RemoveNode (const Standard_Integer theIndex, const Standard_Boolean isForce=Standard_False)
 Removes node from the mesh in case if it has no connected links and its type is Free. More...
 
const BRepMesh::ListOfIntegerLinksConnectedTo (const Standard_Integer theIndex) const
 Get list of links attached to the node with the given index. More...
 
API for accessing mesh links.
Standard_Integer NbLinks () const
 Returns number of links. More...
 
Standard_Integer AddLink (const BRepMesh_Edge &theLink)
 Adds link to the mesh if it is not already in the mesh. More...
 
Standard_Integer IndexOf (const BRepMesh_Edge &theLink) const
 Finds the index of the given link. More...
 
const BRepMesh_EdgeGetLink (const Standard_Integer theIndex)
 Get link by the index. More...
 
const BRepMesh::MapOfIntegerLinksOfDomain () const
 Returns map of indices of links registered in mesh. More...
 
Standard_Boolean SubstituteLink (const Standard_Integer theIndex, const BRepMesh_Edge &theNewLink)
 Substitutes the link with the given index by new one. More...
 
void RemoveLink (const Standard_Integer theIndex, const Standard_Boolean isForce=Standard_False)
 Removes link from the mesh in case if it has no connected elements and its type is Free. More...
 
const BRepMesh_PairOfIndexElementsConnectedTo (const Standard_Integer theLinkIndex) const
 Returns indices of elements conected to the link with the given index. More...
 
API for accessing mesh elements.
Standard_Integer NbElements () const
 Returns number of links. More...
 
Standard_Integer AddElement (const BRepMesh_Triangle &theElement)
 Adds element to the mesh if it is not already in the mesh. More...
 
Standard_Integer IndexOf (const BRepMesh_Triangle &theElement) const
 Finds the index of the given element. More...
 
const BRepMesh_TriangleGetElement (const Standard_Integer theIndex)
 Get element by the index. More...
 
const BRepMesh::MapOfIntegerElementsOfDomain () const
 Returns map of indices of elements registered in mesh. More...
 
Standard_Boolean SubstituteElement (const Standard_Integer theIndex, const BRepMesh_Triangle &theNewElement)
 Substitutes the element with the given index by new one. More...
 
void RemoveElement (const Standard_Integer theIndex)
 Removes element from the mesh. More...
 
void ElementNodes (const BRepMesh_Triangle &theElement, Standard_Integer(&theNodes)[3])
 Returns indices of nodes forming the given element. More...
 
- Public Member Functions inherited from Standard_Transient
 Standard_Transient ()
 Empty constructor. More...
 
 Standard_Transient (const Standard_Transient &)
 Copy constructor – does nothing. More...
 
Standard_Transientoperator= (const Standard_Transient &)
 Assignment operator, needed to avoid copying reference counter. More...
 
virtual ~Standard_Transient ()
 Destructor must be virtual. More...
 
virtual void Delete () const
 Memory deallocator for transient classes. More...
 
virtual const opencascade::handle< Standard_Type > & DynamicType () const
 Returns a type descriptor about this object. More...
 
Standard_Boolean IsInstance (const opencascade::handle< Standard_Type > &theType) const
 Returns a true value if this is an instance of Type. More...
 
Standard_Boolean IsInstance (const Standard_CString theTypeName) const
 Returns a true value if this is an instance of TypeName. More...
 
Standard_Boolean IsKind (const opencascade::handle< Standard_Type > &theType) const
 Returns true if this is an instance of Type or an instance of any class that inherits from Type. Note that multiple inheritance is not supported by OCCT RTTI mechanism. More...
 
Standard_Boolean IsKind (const Standard_CString theTypeName) const
 Returns true if this is an instance of TypeName or an instance of any class that inherits from TypeName. Note that multiple inheritance is not supported by OCCT RTTI mechanism. More...
 
Standard_TransientThis () const
 Returns non-const pointer to this object (like const_cast). For protection against creating handle to objects allocated in stack or call from constructor, it will raise exception Standard_ProgramError if reference counter is zero. More...
 
Standard_Integer GetRefCount () const
 Get the reference counter of this object. More...
 
void IncrementRefCounter () const
 Increments the reference counter of this object. More...
 
Standard_Integer DecrementRefCounter () const
 Decrements the reference counter of this object; returns the decremented value. More...
 

Auxilary API

void Statistics (Standard_OStream &theStream) const
 Dumps information about this structure. More...
 
const Handle< NCollection_IncAllocator > & Allocator () const
 Returns memory allocator used by the structure. More...
 
BRepMesh::HVertexToolData ()
 Gives the data structure for initialization of cell size and tolerance. More...
 
void ClearDomain ()
 Removes all elements. More...
 
void ClearDeleted ()
 Substitutes deleted items by the last one from corresponding map to have only non-deleted elements, links or nodes in the structure. More...
 

Additional Inherited Members

- Public Types inherited from Standard_Transient
typedef void base_type
 Returns a type descriptor about this object. More...
 
- Static Public Member Functions inherited from Standard_Transient
static const char * get_type_name ()
 Returns a type descriptor about this object. More...
 
static const opencascade::handle< Standard_Type > & get_type_descriptor ()
 Returns type descriptor of Standard_Transient class. More...
 

Detailed Description

Describes the data structure necessary for the mesh algorithms in two dimensions plane or on surface by meshing in UV space.

Constructor & Destructor Documentation

◆ BRepMesh_DataStructureOfDelaun()

BRepMesh_DataStructureOfDelaun::BRepMesh_DataStructureOfDelaun ( const Handle< NCollection_IncAllocator > &  theAllocator,
const Standard_Integer  theReservedNodeSize = 100 
)

Constructor.

Parameters
theAllocatormemory allocator to be used by internal structures.
theReservedNodeSizepresumed number of nodes in this mesh.

Member Function Documentation

◆ AddElement()

Standard_Integer BRepMesh_DataStructureOfDelaun::AddElement ( const BRepMesh_Triangle theElement)

Adds element to the mesh if it is not already in the mesh.

Parameters
theElementelement to be added to the mesh.
Returns
index of the element in the structure.

◆ AddLink()

Standard_Integer BRepMesh_DataStructureOfDelaun::AddLink ( const BRepMesh_Edge theLink)

Adds link to the mesh if it is not already in the mesh.

Parameters
theLinklink to be added to the mesh.
Returns
index of the link in the structure.

◆ AddNode()

Standard_Integer BRepMesh_DataStructureOfDelaun::AddNode ( const BRepMesh_Vertex theNode,
const Standard_Boolean  isForceAdd = Standard_False 
)

Adds node to the mesh if it is not already in the mesh.

Parameters
theNodenode to be added to the mesh.
isForceAddadds the given node to structure without checking on coincidence with other nodes.
Returns
index of the node in the structure.

◆ Allocator()

const Handle< NCollection_IncAllocator >& BRepMesh_DataStructureOfDelaun::Allocator ( ) const
inline

Returns memory allocator used by the structure.

◆ ClearDeleted()

void BRepMesh_DataStructureOfDelaun::ClearDeleted ( )
inline

Substitutes deleted items by the last one from corresponding map to have only non-deleted elements, links or nodes in the structure.

◆ ClearDomain()

void BRepMesh_DataStructureOfDelaun::ClearDomain ( )

Removes all elements.

◆ Data()

BRepMesh::HVertexTool& BRepMesh_DataStructureOfDelaun::Data ( )
inline

Gives the data structure for initialization of cell size and tolerance.

◆ ElementNodes()

void BRepMesh_DataStructureOfDelaun::ElementNodes ( const BRepMesh_Triangle theElement,
Standard_Integer(&)  theNodes[3] 
)

Returns indices of nodes forming the given element.

Parameters
theElementelement which nodes should be retrieved.
[out]theNodesnodes of the given element.

◆ ElementsConnectedTo()

const BRepMesh_PairOfIndex& BRepMesh_DataStructureOfDelaun::ElementsConnectedTo ( const Standard_Integer  theLinkIndex) const
inline

Returns indices of elements conected to the link with the given index.

Parameters
theLinkIndexindex of link whose data should be retrieved.
Returns
indices of elements conected to the link.

◆ ElementsOfDomain()

const BRepMesh::MapOfInteger& BRepMesh_DataStructureOfDelaun::ElementsOfDomain ( ) const
inline

Returns map of indices of elements registered in mesh.

◆ GetElement()

const BRepMesh_Triangle& BRepMesh_DataStructureOfDelaun::GetElement ( const Standard_Integer  theIndex)
inline

Get element by the index.

Parameters
theIndexindex of an element.
Returns
element with the given index.

◆ GetLink()

const BRepMesh_Edge& BRepMesh_DataStructureOfDelaun::GetLink ( const Standard_Integer  theIndex)
inline

Get link by the index.

Parameters
theIndexindex of a link.
Returns
link with the given index.

◆ GetNode()

const BRepMesh_Vertex& BRepMesh_DataStructureOfDelaun::GetNode ( const Standard_Integer  theIndex)
inline

Get node by the index.

Parameters
theIndexindex of a node.
Returns
node with the given index.

◆ IndexOf() [1/3]

Standard_Integer BRepMesh_DataStructureOfDelaun::IndexOf ( const BRepMesh_Vertex theNode)
inline

Finds the index of the given node.

Parameters
theNodenode to find.
Returns
index of the given element of zero if node is not in the mesh.

◆ IndexOf() [2/3]

Standard_Integer BRepMesh_DataStructureOfDelaun::IndexOf ( const BRepMesh_Edge theLink) const
inline

Finds the index of the given link.

Parameters
theLinklink to find.
Returns
index of the given element of zero if link is not in the mesh.

◆ IndexOf() [3/3]

Standard_Integer BRepMesh_DataStructureOfDelaun::IndexOf ( const BRepMesh_Triangle theElement) const
inline

Finds the index of the given element.

Parameters
theElementelement to find.
Returns
index of the given element of zero if element is not in the mesh.

◆ LinksConnectedTo()

const BRepMesh::ListOfInteger& BRepMesh_DataStructureOfDelaun::LinksConnectedTo ( const Standard_Integer  theIndex) const
inline

Get list of links attached to the node with the given index.

Parameters
theIndexindex of node whose links should be retrieved.
Returns
list of links attached to the node.

◆ LinksOfDomain()

const BRepMesh::MapOfInteger& BRepMesh_DataStructureOfDelaun::LinksOfDomain ( ) const
inline

Returns map of indices of links registered in mesh.

◆ NbElements()

Standard_Integer BRepMesh_DataStructureOfDelaun::NbElements ( ) const
inline

Returns number of links.

◆ NbLinks()

Standard_Integer BRepMesh_DataStructureOfDelaun::NbLinks ( ) const
inline

Returns number of links.

◆ NbNodes()

Standard_Integer BRepMesh_DataStructureOfDelaun::NbNodes ( ) const
inline

Returns number of nodes.

◆ operator()()

const BRepMesh_Vertex& BRepMesh_DataStructureOfDelaun::operator() ( const Standard_Integer  theIndex)
inline

Alias for GetNode.

◆ RemoveElement()

void BRepMesh_DataStructureOfDelaun::RemoveElement ( const Standard_Integer  theIndex)

Removes element from the mesh.

Parameters
theIndexindex of element to be removed.

◆ RemoveLink()

void BRepMesh_DataStructureOfDelaun::RemoveLink ( const Standard_Integer  theIndex,
const Standard_Boolean  isForce = Standard_False 
)

Removes link from the mesh in case if it has no connected elements and its type is Free.

Parameters
theIndexindex of link to be removed.
isForceif TRUE link will be removed even if movability is not Free.

◆ RemoveNode()

void BRepMesh_DataStructureOfDelaun::RemoveNode ( const Standard_Integer  theIndex,
const Standard_Boolean  isForce = Standard_False 
)
inline

Removes node from the mesh in case if it has no connected links and its type is Free.

Parameters
theIndexindex of node to be removed.
isForceif TRUE node will be removed even if movability is not Free.

◆ Statistics()

void BRepMesh_DataStructureOfDelaun::Statistics ( Standard_OStream theStream) const

Dumps information about this structure.

Parameters
theStreamstream to be used for dump.

◆ SubstituteElement()

Standard_Boolean BRepMesh_DataStructureOfDelaun::SubstituteElement ( const Standard_Integer  theIndex,
const BRepMesh_Triangle theNewElement 
)

Substitutes the element with the given index by new one.

Parameters
theIndexindex of element to be substituted.
theNewLinksubstituting element.
Returns
FALSE in case if new element is already in the structure, TRUE elsewhere.

◆ SubstituteLink()

Standard_Boolean BRepMesh_DataStructureOfDelaun::SubstituteLink ( const Standard_Integer  theIndex,
const BRepMesh_Edge theNewLink 
)

Substitutes the link with the given index by new one.

Parameters
theIndexindex of link to be substituted.
theNewLinksubstituting link.
Returns
FALSE in case if new link is already in the structure, TRUE elsewhere.

◆ SubstituteNode()

Standard_Boolean BRepMesh_DataStructureOfDelaun::SubstituteNode ( const Standard_Integer  theIndex,
const BRepMesh_Vertex theNewNode 
)

Substitutes the node with the given index by new one.

Parameters
theIndexindex of node to be substituted.
theNewNodesubstituting node.
Returns
FALSE in case if new node is already in the structure, TRUE elsewhere.

The documentation for this class was generated from the following file: