24 #ifndef vtkCellLinks_h
25 #define vtkCellLinks_h
28 #include "vtkCommonDataModelModule.h"
32 VTK_ABI_NAMESPACE_BEGIN
235 if (cells[i] == cellId)
237 for (
vtkIdType j = i; j < (ncells - 1); j++)
239 cells[j] = cells[j + 1];
258 memcpy(cells, this->
Array[ptId].cells,
259 static_cast<size_t>(this->
Array[ptId].ncells) *
sizeof(
vtkIdType));
264 VTK_ABI_NAMESPACE_END
an abstract base class for classes that build topological links from points to cells
object to represent cell connectivity
object represents upward pointers from points to list of cells using each point
void Squeeze() override
Reclaim any unused memory.
void InsertNextCellReference(vtkIdType ptId, vtkIdType cellId)
Insert a cell id into the list of cells (at the end) using the cell id provided.
void InsertCellReference(vtkIdType ptId, vtkIdType pos, vtkIdType cellId)
Insert a cell id into the list of cells using the point.
void BuildLinks() override
Build the link list array from the input dataset.
void RemoveCellReference(vtkIdType cellId, vtkIdType ptId)
Delete the reference to the cell (cellId) from the point (ptId).
void Allocate(vtkIdType numLinks, vtkIdType ext=1000)
Allocate the specified number of links (i.e., number of points) that will be built.
unsigned long GetActualMemorySize() override
Return the memory in kibibytes (1024 bytes) consumed by this cell links array.
void DeepCopy(vtkAbstractCellLinks *src) override
Standard DeepCopy method.
Link * Resize(vtkIdType sz)
void AllocateLinks(vtkIdType n)
static vtkCellLinks * New()
Standard methods to instantiate, print, and obtain type information.
void Reset() override
Reset to a state of no entries without freeing the memory.
void PrintSelf(ostream &os, vtkIndent indent) override
Standard methods to instantiate, print, and obtain type information.
void AddCellReference(vtkIdType cellId, vtkIdType ptId)
Add the reference to the cell (cellId) from the point (ptId).
void ShallowCopy(vtkAbstractCellLinks *src) override
Standard ShallowCopy method.
void Initialize() override
Clear out any previously allocated data structures.
void ResizeCellList(vtkIdType ptId, int size)
Change the length of a point's link list (i.e., list of cells using a point) by the size specified.
vtkIdType InsertNextPoint(int numLinks)
Insert a new point into the cell-links data structure.
void IncrementLinkCount(vtkIdType ptId)
Increment the count of the number of cells using the point.
vtkIdType * GetCells(vtkIdType ptId)
Return a list of cell ids using the point.
Link & GetLink(vtkIdType ptId)
Get a link structure given a point id.
void SelectCells(vtkIdType minMaxDegree[2], unsigned char *cellSelection) override
Select all cells with a point degree in the range [minDegree,maxDegree).
vtkIdType GetNcells(vtkIdType ptId)
Get the number of cells using the point specified by ptId.
std::shared_ptr< Link > ArraySharedPtr
void DeletePoint(vtkIdType ptId)
Delete point (and storage) by destroying links to using cells.
abstract class to specify dataset behavior
a simple class to control print indentation