SMDS_Down2D Class Referenceabstract

#include <SMDS_Downward.hxx>

Public Member Functions

virtual void getNodeIds (int cellId, std::set< int > &nodeSet)
 
virtual int getNumberOfUpCells (int cellId)
 
virtual const intgetUpCells (int cellId)
 
virtual const unsigned char * getUpTypes (int cellId)
 
- Public Member Functions inherited from SMDS_Downward
virtual const intgetDownCells (int cellId)
 
virtual const unsigned char * getDownTypes (int cellId)
 
int getMaxId ()
 
virtual void getNodeIds (int cellId, std::set< int > &nodeSet)=0
 
virtual int getNodes (int cellId, int *nodevec)
 
virtual int getNumberOfDownCells (int cellId)
 
virtual int getNumberOfUpCells (int cellId)=0
 
virtual void getOrderedNodesOfFace (int cellId, std::vector< vtkIdType > &orderedNodes)
 
virtual const intgetUpCells (int cellId)=0
 
virtual const unsigned char * getUpTypes (int cellId)=0
 
int getVtkCellId (int cellId)
 

Protected Member Functions

virtual void addUpCell (int cellId, int upCellId, unsigned char aType)
 Id's are downward connectivity id's. More...
 
virtual void allocate (int nbElems)
 
virtual void compactStorage ()
 
virtual void computeEdgesWithNodes (int cellId, ListElemByNodesType &facesWithNodes)=0
 
int computeVolumeIds (ElemByNodesType &faceByNodes, int *ids)
 
int computeVolumeIds (int cellId, int *ids)
 
int computeVolumeIdsFromNodesFace (int *nodes, int nbNodes, int *ids)
 
int FindEdgeByNodes (int cellId, ElemByNodesType &edgeByNodes)
 
virtual int getNodeSet (int cellId, int *nodeSet)
 
bool isInFace (int cellId, int *pts, int npts)
 
void setTempNodes (int cellId, ElemByNodesType &faceByNodes)
 
void setTempNodes (int cellId, int vtkId)
 
 SMDS_Down2D (SMDS_UnstructuredGrid *grid, int nbDownCells)
 
 ~SMDS_Down2D ()
 
- Protected Member Functions inherited from SMDS_Downward
int addCell (int vtkId=-1)
 
virtual void addDownCell (int cellId, int lowCellId, unsigned char aType)
 Id's are downward connectivity id's. More...
 
virtual void addUpCell (int cellId, int upCellId, unsigned char aType)
 Id's are downward connectivity id's. More...
 
virtual void allocate (int nbElems)=0
 
virtual void compactStorage ()=0
 
virtual int getNodeSet (int cellId, int *nodeSet)
 
virtual void initCell (int cellId)
 
 SMDS_Downward (SMDS_UnstructuredGrid *grid, int nbDownCells)
 
virtual ~SMDS_Downward ()
 

Friends

class SMDS_Down1D
 
class SMDS_UnstructuredGrid
 

Additional Inherited Members

- Static Public Member Functions inherited from SMDS_Downward
static int getCellDimension (unsigned char cellType)
 

Constructor & Destructor Documentation

◆ SMDS_Down2D()

SMDS_Down2D::SMDS_Down2D ( SMDS_UnstructuredGrid grid,
int  nbDownCells 
)
protected

◆ ~SMDS_Down2D()

SMDS_Down2D::~SMDS_Down2D ( )
protected

Member Function Documentation

◆ addUpCell()

void SMDS_Down2D::addUpCell ( int  cellId,
int  upCellId,
unsigned char  aType 
)
protectedvirtual

Id's are downward connectivity id's.

add a downward entity of dimension n+1 to a given cell. Actual implementation is done in derived methods.

Parameters
cellIdindex of the children cell (dimension n) in the downward structure relative to a vtk cell type.
upCellIdindex of the parent cell to add (dimension n+1)
aTypevtk cell type of the cell to add (needed to find the SMDS_Downward structure containing the cell to add).

Reimplemented from SMDS_Downward.

◆ allocate()

void SMDS_Down2D::allocate ( int  nbElems)
protectedvirtual

Resize the downward connectivity storage vector if needed.

Parameters
nbElemstotal number of elements of the same type required

Implements SMDS_Downward.

References SMDS_Mesh::chunkSize.

◆ compactStorage()

void SMDS_Down2D::compactStorage ( )
protectedvirtual

Implements SMDS_Downward.

◆ computeEdgesWithNodes()

virtual void SMDS_Down2D::computeEdgesWithNodes ( int  cellId,
ListElemByNodesType facesWithNodes 
)
protectedpure virtual

◆ computeVolumeIds() [1/2]

int SMDS_Down2D::computeVolumeIds ( ElemByNodesType faceByNodes,
int ids 
)
protected

Find in vtkUnstructuredGrid the volumes containing a face described by it's nodes Search the volumes containing a face, to store the info in SMDS_Down2D for later uses with SMDS_Down2D::getUpCells and SMDS_Down2D::getUpTypes. A face belongs to 0, 1 or 2 volumes, identified by their id in vtkUnstructuredGrid.

Parameters
faceByNodes
idsa couple of vtkId, initialized at -1 (no parent volume)
Returns
number of volumes (0, 1 or 2)

References computeVolumeIdsFromNodesFace(), ElemByNodesType::nbNodes, and ElemByNodesType::nodeIds.

◆ computeVolumeIds() [2/2]

int SMDS_Down2D::computeVolumeIds ( int  cellId,
int ids 
)
protected

Find in vtkUnstructuredGrid the volumes containing a face already stored in vtkUnstructuredGrid. Search the volumes containing a face, to store the info in SMDS_Down2D for later uses with SMDS_Down2D::getUpCells and SMDS_Down2D::getUpTypes. A face belongs to 0, 1 or 2 volumes, identified by their id in vtkUnstructuredGrid.

Parameters
cellIdthe face cell id in vkUnstructuredGrid
idsa couple of vtkId, initialized at -1 (no parent volume)
Returns
number of volumes (0, 1 or 2)

References computeVolumeIdsFromNodesFace().

Referenced by SMDS_UnstructuredGrid::BuildDownwardConnectivity().

◆ computeVolumeIdsFromNodesFace()

int SMDS_Down2D::computeVolumeIdsFromNodesFace ( int pts,
int  npts,
int ids 
)
protected

Find in vtkUnstructuredGrid the volumes containing a face described by it's nodes Search the volumes containing a face, to store the info in SMDS_Down2D for later uses with SMDS_Down2D::getUpCells and SMDS_Down2D::getUpTypes. A face belongs to 0, 1 or 2 volumes, identified by their id in vtkUnstructuredGrid.

Parameters
ptsarray of vtk node id's
nptsnumber of nodes
ids
Returns
number of volumes (0, 1 or 2)

References SMDS_Downward::getCellDimension().

Referenced by SMDS_UnstructuredGrid::BuildDownwardConnectivity(), and computeVolumeIds().

◆ FindEdgeByNodes()

int SMDS_Down2D::FindEdgeByNodes ( int  cellId,
ElemByNodesType edgeByNodes 
)
protected

◆ getNodeIds()

void SMDS_Down2D::getNodeIds ( int  cellId,
std::set< int > &  nodeSet 
)
virtual

Implements SMDS_Downward.

◆ getNodeSet()

int SMDS_Down2D::getNodeSet ( int  cellId,
int nodeSet 
)
protectedvirtual

Reimplemented from SMDS_Downward.

◆ getNumberOfUpCells()

int SMDS_Down2D::getNumberOfUpCells ( int  cellId)
virtual

Implements SMDS_Downward.

◆ getUpCells()

const int * SMDS_Down2D::getUpCells ( int  cellId)
virtual

Implements SMDS_Downward.

◆ getUpTypes()

const unsigned char * SMDS_Down2D::getUpTypes ( int  cellId)
virtual

Implements SMDS_Downward.

◆ isInFace()

bool SMDS_Down2D::isInFace ( int  cellId,
int pts,
int  npts 
)
protected

Find if all the nodes belongs to the face.

Parameters
cellIdthe face cell Id
nodeSetset of node id's to be found in the face list of nodes
Returns

Referenced by SMDS_Down1D::computeFaces().

◆ setTempNodes() [1/2]

void SMDS_Down2D::setTempNodes ( int  cellId,
ElemByNodesType faceByNodes 
)
protected

◆ setTempNodes() [2/2]

void SMDS_Down2D::setTempNodes ( int  cellId,
int  vtkId 
)
protected

Friends And Related Function Documentation

◆ SMDS_Down1D

friend class SMDS_Down1D
friend

◆ SMDS_UnstructuredGrid


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