Version: 9.16.0
StdMeshers::Cartesian3D::Hexahedron::_volumeDef Struct Reference

Data Structures

struct  _linkDef
 
struct  _nodeDef
 

Public Types

typedef void * _ptr
 

Public Member Functions

 _volumeDef ()
 
 ~_volumeDef ()
 
 _volumeDef (_volumeDef &other)
 
size_t size () const
 
_volumeDefat (int index)
 
void Set (_Node **nodes, int nb)
 
void SetNext (_volumeDef *vd)
 
bool IsEmpty () const
 
bool IsPolyhedron () const
 
std::vector< std::set< std::pair< int, int > > > getPolygonsEdges () const
 Returns a vector of sets of edges like {{ nodeId1, nodeId2 }, { nodeId2, nodeId3 }} where an index of element in the vector is an index of polygon in the volume. More...
 
std::vector< std::set< std::pair< int, int > > > findOpenEdges () const
 Finds polygons with at least one edge not connected to any other polygon. More...
 
int getStartNodeIndex (const int polygon) const
 Returns an index of the first node of the given polygon in the _nodes container. More...
 
std::map< int, std::vector< int > > findOverlappingPolygons () const
 Finds in the volume a polygon with such a set of edges that is a subset of edges of other polygon. More...
 
bool divideOverlappingPolygons ()
 Finds in the volume a polygon with such a set of edges that is a subset of edges of other polygon. More...
 
bool fixOpenEdgesPolygons ()
 Finds polygons with at least one edge not connected to any other polygon, and tries to cap them with new polygons or just remove as invalid. More...
 
bool capOpenEdgesPolygons (const std::vector< std::set< std::pair< int, int > > > &edgesByPolygon)
 Finds polygons with at least one edge not connected to any other polygon, and tries to cap them with new polygons. More...
 
bool removeOpenEdgesPolygons (const std::vector< std::set< std::pair< int, int > > > &edgesByPolygon)
 Finds polygons with at least one edge not connected to any other polygon, and removes all of them. More...
 

Data Fields

std::vector< _nodeDef_nodes
 
std::vector< int > _quantities
 
_volumeDef_next
 
StdMeshers::Cartesian3D::TGeomID _solidID
 
double _size
 
const SMDS_MeshElement_volume
 
std::vector< const SMDS_MeshElement * > _brotherVolume
 
std::vector< SMESH_Block::TShapeID_names
 

Member Typedef Documentation

◆ _ptr

Constructor & Destructor Documentation

◆ _volumeDef() [1/2]

StdMeshers::Cartesian3D::Hexahedron::_volumeDef::_volumeDef ( )

◆ ~_volumeDef()

StdMeshers::Cartesian3D::Hexahedron::_volumeDef::~_volumeDef ( )

◆ _volumeDef() [2/2]

StdMeshers::Cartesian3D::Hexahedron::_volumeDef::_volumeDef ( _volumeDef other)

References _names, _nodes, _quantities, and _volume.

Member Function Documentation

◆ at()

_volumeDef * StdMeshers::Cartesian3D::Hexahedron::_volumeDef::at ( int  index)

◆ capOpenEdgesPolygons()

bool Hexahedron::_volumeDef::capOpenEdgesPolygons ( const std::vector< std::set< std::pair< int, int > > > &  edgesByPolygon)

Finds polygons with at least one edge not connected to any other polygon, and tries to cap them with new polygons.

Returns true if at least one polygon was created.

References MESSAGE.

◆ divideOverlappingPolygons()

bool Hexahedron::_volumeDef::divideOverlappingPolygons ( )

Finds in the volume a polygon with such a set of edges that is a subset of edges of other polygon.

Then we can remove these edges from a larger polygon and have as a result two connected polygons those are next to each other instead of being overlapped. We can't just delete the smaller polygon, because it could be a part of separated volume that can be revealed later in checkPolyhedronValidity(). Returns true if at least one polygon was changed.

References MESSAGE.

◆ findOpenEdges()

std::vector< std::set< std::pair< int, int > > > Hexahedron::_volumeDef::findOpenEdges ( ) const

Finds polygons with at least one edge not connected to any other polygon.

Returns a vector of sets of edges like {{ nodeId1, nodeId2 }, { nodeId2, nodeId3 }} where an index of element in the vector is an index of polygon in the volume. Nodes ids in the pairs are sorted, so index of a first node is always less than second.

References MESSAGE.

◆ findOverlappingPolygons()

std::map< int, std::vector< int > > Hexahedron::_volumeDef::findOverlappingPolygons ( ) const

Finds in the volume a polygon with such a set of edges that is a subset of edges of other polygon.

Returns a map where a key is a larger polygon, the value - is a smaller polygon that is a subset of larger, followed by two nodes those we need to connect in a process of cutting of the first polygon. If the second poly is a complete clone of the first one, both nodes will be -1.

◆ fixOpenEdgesPolygons()

bool Hexahedron::_volumeDef::fixOpenEdgesPolygons ( )

Finds polygons with at least one edge not connected to any other polygon, and tries to cap them with new polygons or just remove as invalid.

Returns true if any of this changes were made.

◆ getPolygonsEdges()

std::vector< std::set< std::pair< int, int > > > Hexahedron::_volumeDef::getPolygonsEdges ( ) const

Returns a vector of sets of edges like {{ nodeId1, nodeId2 }, { nodeId2, nodeId3 }} where an index of element in the vector is an index of polygon in the volume.

Nodes ids in the pairs are sorted, so index of a first node is always less than second.

◆ getStartNodeIndex()

int Hexahedron::_volumeDef::getStartNodeIndex ( const int  polygon) const

Returns an index of the first node of the given polygon in the _nodes container.

◆ IsEmpty()

bool StdMeshers::Cartesian3D::Hexahedron::_volumeDef::IsEmpty ( ) const

References IsEmpty().

Referenced by IsEmpty().

◆ IsPolyhedron()

bool StdMeshers::Cartesian3D::Hexahedron::_volumeDef::IsPolyhedron ( ) const

◆ removeOpenEdgesPolygons()

bool Hexahedron::_volumeDef::removeOpenEdgesPolygons ( const std::vector< std::set< std::pair< int, int > > > &  edgesByPolygon)

Finds polygons with at least one edge not connected to any other polygon, and removes all of them.

Returns true if at least polygon one was removed.

References MESSAGE.

◆ Set()

◆ SetNext()

void StdMeshers::Cartesian3D::Hexahedron::_volumeDef::SetNext ( _volumeDef vd)

◆ size()

size_t StdMeshers::Cartesian3D::Hexahedron::_volumeDef::size ( ) const

Field Documentation

◆ _brotherVolume

std::vector<const SMDS_MeshElement*> StdMeshers::Cartesian3D::Hexahedron::_volumeDef::_brotherVolume

◆ _names

std::vector< SMESH_Block::TShapeID > StdMeshers::Cartesian3D::Hexahedron::_volumeDef::_names

◆ _next

◆ _nodes

◆ _quantities

◆ _size

◆ _solidID

◆ _volume

const SMDS_MeshElement* StdMeshers::Cartesian3D::Hexahedron::_volumeDef::_volume