VTK  9.5.20251209
vtkGenericCell.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
99
100#ifndef vtkGenericCell_h
101#define vtkGenericCell_h
102
103#include "vtkCell.h"
104#include "vtkCommonDataModelModule.h" // For export macro
105
106VTK_ABI_NAMESPACE_BEGIN
107class VTKCOMMONDATAMODEL_EXPORT vtkGenericCell : public vtkCell
108{
109public:
114
115 vtkTypeMacro(vtkGenericCell, vtkCell);
116 void PrintSelf(ostream& os, vtkIndent indent) override;
117
122 void SetPoints(vtkPoints* points);
123
128 void SetPointIds(vtkIdList* pointIds);
129
131
134 void ShallowCopy(vtkCell* c) override;
135 void DeepCopy(vtkCell* c) override;
136 int GetCellType() override;
137 int GetCellDimension() override;
138 int IsLinear() VTK_FUTURE_CONST override;
140 void Initialize() override;
141 int RequiresExplicitFaceRepresentation() VTK_FUTURE_CONST override;
145 int GetNumberOfEdges() override;
146 int GetNumberOfFaces() override;
147 vtkCell* GetEdge(int edgeId) override;
148 vtkCell* GetFace(int faceId) override;
149 int CellBoundary(int subId, const double pcoords[3], vtkIdList* pts) override;
150 int EvaluatePosition(const double x[3], double closestPoint[3], int& subId, double pcoords[3],
151 double& dist2, double weights[]) override;
152 void EvaluateLocation(int& subId, const double pcoords[3], double x[3], double* weights) override;
153 void Contour(double value, vtkDataArray* cellScalars, vtkIncrementalPointLocator* locator,
154 vtkCellArray* verts, vtkCellArray* lines, vtkCellArray* polys, vtkPointData* inPd,
155 vtkPointData* outPd, vtkCellData* inCd, vtkIdType cellId, vtkCellData* outCd) override;
156 void Clip(double value, vtkDataArray* cellScalars, vtkIncrementalPointLocator* locator,
157 vtkCellArray* connectivity, vtkPointData* inPd, vtkPointData* outPd, vtkCellData* inCd,
158 vtkIdType cellId, vtkCellData* outCd, int insideOut) override;
159 int IntersectWithLine(const double p1[3], const double p2[3], double tol, double& t, double x[3],
160 double pcoords[3], int& subId) override;
161 int Triangulate(int index, vtkIdList* ptIds, vtkPoints* pts) override;
162 int TriangulateLocalIds(int index, vtkIdList* ptIds) override;
163 int TriangulateIds(int index, vtkIdList* ptIds) override;
165 int subId, const double pcoords[3], const double* values, int dim, double* derivs) override;
166 int GetParametricCenter(double pcoords[3]) override;
167 double* GetParametricCoords() override;
168 int IsPrimaryCell() VTK_FUTURE_CONST override;
170
172
176 void InterpolateFunctions(const double pcoords[3], double* weights) override;
177 void InterpolateDerivs(const double pcoords[3], double* derivs) override;
179
187 void SetCellType(int cellType);
236
246 static vtkCell* InstantiateCell(int cellType);
247
248 vtkCell* GetRepresentativeCell() { return this->Cell; }
249
250protected:
252 ~vtkGenericCell() override;
253
256
257private:
258 vtkGenericCell(const vtkGenericCell&) = delete;
259 void operator=(const vtkGenericCell&) = delete;
260};
261
262VTK_ABI_NAMESPACE_END
263#endif
object to represent cell connectivity
represent and manipulate cell attribute data
void SetCellTypeToLagrangeCurve()
void SetCellTypeToHexahedron()
void SetCellTypeToQuadraticLinearWedge()
int IsLinear() VTK_FUTURE_CONST override
See the vtkCell API for descriptions of these methods.
static vtkCell * InstantiateCell(int cellType)
Instantiate a new vtkCell based on it's cell type value.
void EvaluateLocation(int &subId, const double pcoords[3], double x[3], double *weights) override
See the vtkCell API for descriptions of these methods.
void SetCellTypeToLagrangeWedge()
void Initialize() override
See the vtkCell API for descriptions of these methods.
vtkCell * GetFace(int faceId) override
See the vtkCell API for descriptions of these methods.
void SetCellTypeToQuadraticWedge()
void SetCellTypeToQuadraticPolygon()
int CellBoundary(int subId, const double pcoords[3], vtkIdList *pts) override
See the vtkCell API for descriptions of these methods.
void SetCellTypeToPyramid()
void SetCellTypeToQuadraticTetra()
int SetCellFaces(vtkCellArray *faces)
See the vtkCell API for descriptions of these methods.
void SetCellTypeToTriangleStrip()
void SetCellTypeToPixel()
int RequiresInitialization() override
See the vtkCell API for descriptions of these methods.
vtkCell * GetRepresentativeCell()
int EvaluatePosition(const double x[3], double closestPoint[3], int &subId, double pcoords[3], double &dist2, double weights[]) override
See the vtkCell API for descriptions of these methods.
int IsPrimaryCell() VTK_FUTURE_CONST override
See the vtkCell API for descriptions of these methods.
void SetCellTypeToQuadraticQuad()
vtkCellArray * GetCellFaces()
See the vtkCell API for descriptions of these methods.
void SetCellTypeToQuadraticLinearQuad()
int TriangulateIds(int index, vtkIdList *ptIds) override
See the vtkCell API for descriptions of these methods.
int GetParametricCenter(double pcoords[3]) override
See the vtkCell API for descriptions of these methods.
void SetCellTypeToBezierWedge()
void SetCellTypeToTetra()
~vtkGenericCell() override
void Clip(double value, vtkDataArray *cellScalars, vtkIncrementalPointLocator *locator, vtkCellArray *connectivity, vtkPointData *inPd, vtkPointData *outPd, vtkCellData *inCd, vtkIdType cellId, vtkCellData *outCd, int insideOut) override
See the vtkCell API for descriptions of these methods.
static vtkGenericCell * New()
Create handle to any type of cell; by default a vtkEmptyCell.
void SetCellTypeToLagrangeTetra()
void Derivatives(int subId, const double pcoords[3], const double *values, int dim, double *derivs) override
See the vtkCell API for descriptions of these methods.
void Contour(double value, vtkDataArray *cellScalars, vtkIncrementalPointLocator *locator, vtkCellArray *verts, vtkCellArray *lines, vtkCellArray *polys, vtkPointData *inPd, vtkPointData *outPd, vtkCellData *inCd, vtkIdType cellId, vtkCellData *outCd) override
See the vtkCell API for descriptions of these methods.
void SetCellTypeToPolyhedron()
void InterpolateDerivs(const double pcoords[3], double *derivs) override
Compute the interpolation functions/derivatives (aka shape functions/derivatives)
void SetCellTypeToBezierTetra()
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void SetCellTypeToQuadraticHexahedron()
void SetCellTypeToVoxel()
void SetPoints(vtkPoints *points)
Set the points object to use for this cell.
void SetCellTypeToTriQuadraticHexahedron()
vtkCell * CellStore[VTK_NUMBER_OF_CELL_TYPES]
int TriangulateLocalIds(int index, vtkIdList *ptIds) override
See the vtkCell API for descriptions of these methods.
int IntersectWithLine(const double p1[3], const double p2[3], double tol, double &t, double x[3], double pcoords[3], int &subId) override
See the vtkCell API for descriptions of these methods.
void SetCellTypeToBiQuadraticQuadraticHexahedron()
void SetCellTypeToBiQuadraticQuad()
void SetCellTypeToCubicLine()
double * GetParametricCoords() override
See the vtkCell API for descriptions of these methods.
int GetNumberOfEdges() override
See the vtkCell API for descriptions of these methods.
void SetCellTypeToConvexPointSet()
int GetCellDimension() override
See the vtkCell API for descriptions of these methods.
void DeepCopy(vtkCell *c) override
See the vtkCell API for descriptions of these methods.
void SetCellTypeToVertex()
void SetCellTypeToBezierCurve()
int GetNumberOfFaces() override
See the vtkCell API for descriptions of these methods.
void SetCellTypeToLagrangeTriangle()
void SetCellTypeToWedge()
void SetCellType(int cellType)
This method is used to support the vtkDataSet::GetCell(vtkGenericCell *) method.
int Triangulate(int index, vtkIdList *ptIds, vtkPoints *pts) override
See the vtkCell API for descriptions of these methods.
void SetCellTypeToTriangle()
void SetCellTypeToQuadraticPyramid()
void SetCellTypeToQuadraticEdge()
int GetCellType() override
See the vtkCell API for descriptions of these methods.
void SetCellTypeToBiQuadraticQuadraticWedge()
int RequiresExplicitFaceRepresentation() VTK_FUTURE_CONST override
See the vtkCell API for descriptions of these methods.
void SetCellTypeToBiQuadraticTriangle()
void SetCellTypeToPolyLine()
void SetCellTypeToPentagonalPrism()
void SetCellTypeToPolygon()
void SetCellTypeToBezierQuadrilateral()
void SetCellTypeToLagrangeQuadrilateral()
void SetCellTypeToBezierTriangle()
void InterpolateFunctions(const double pcoords[3], double *weights) override
Compute the interpolation functions/derivatives (aka shape functions/derivatives)
vtkCell * GetEdge(int edgeId) override
See the vtkCell API for descriptions of these methods.
void SetCellTypeToHexagonalPrism()
void SetCellTypeToBezierHexahedron()
void SetCellTypeToEmptyCell()
void SetCellTypeToLagrangeHexahedron()
void SetCellTypeToPolyVertex()
void ShallowCopy(vtkCell *c) override
See the vtkCell API for descriptions of these methods.
void SetPointIds(vtkIdList *pointIds)
Set the point ids to use for this cell.
void SetCellTypeToTriQuadraticPyramid()
void SetCellTypeToQuadraticTriangle()
list of point or cell ids
Definition vtkIdList.h:133
Abstract class in support of both point location and point insertion.
a simple class to control print indentation
Definition vtkIndent.h:108
represent and manipulate point attribute data
represent and manipulate 3D points
Definition vtkPoints.h:139
@ VTK_VOXEL
Definition vtkCellType.h:47
@ VTK_QUADRATIC_HEXAHEDRON
Definition vtkCellType.h:60
@ VTK_TRIANGLE_STRIP
Definition vtkCellType.h:42
@ VTK_BIQUADRATIC_QUADRATIC_HEXAHEDRON
Definition vtkCellType.h:69
@ VTK_NUMBER_OF_CELL_TYPES
@ VTK_LAGRANGE_CURVE
@ VTK_PYRAMID
Definition vtkCellType.h:50
@ VTK_PIXEL
Definition vtkCellType.h:44
@ VTK_QUADRATIC_WEDGE
Definition vtkCellType.h:61
@ VTK_BEZIER_WEDGE
@ VTK_BIQUADRATIC_QUAD
Definition vtkCellType.h:63
@ VTK_LAGRANGE_QUADRILATERAL
@ VTK_POLY_LINE
Definition vtkCellType.h:40
@ VTK_TRIQUADRATIC_PYRAMID
Definition vtkCellType.h:65
@ VTK_TRIANGLE
Definition vtkCellType.h:41
@ VTK_BEZIER_TRIANGLE
@ VTK_POLYGON
Definition vtkCellType.h:43
@ VTK_EMPTY_CELL
Definition vtkCellType.h:36
@ VTK_QUADRATIC_PYRAMID
Definition vtkCellType.h:62
@ VTK_POLYHEDRON
Definition vtkCellType.h:79
@ VTK_TRIQUADRATIC_HEXAHEDRON
Definition vtkCellType.h:64
@ VTK_TETRA
Definition vtkCellType.h:46
@ VTK_LINE
Definition vtkCellType.h:39
@ VTK_CONVEX_POINT_SET
Definition vtkCellType.h:76
@ VTK_BEZIER_HEXAHEDRON
@ VTK_LAGRANGE_WEDGE
@ VTK_LAGRANGE_HEXAHEDRON
@ VTK_PENTAGONAL_PRISM
Definition vtkCellType.h:51
@ VTK_QUADRATIC_QUAD
Definition vtkCellType.h:57
@ VTK_WEDGE
Definition vtkCellType.h:49
@ VTK_LAGRANGE_TETRAHEDRON
@ VTK_BEZIER_CURVE
@ VTK_HEXAGONAL_PRISM
Definition vtkCellType.h:52
@ VTK_BEZIER_QUADRILATERAL
@ VTK_QUADRATIC_LINEAR_WEDGE
Definition vtkCellType.h:67
@ VTK_HEXAHEDRON
Definition vtkCellType.h:48
@ VTK_CUBIC_LINE
Definition vtkCellType.h:73
@ VTK_LAGRANGE_TRIANGLE
@ VTK_QUADRATIC_POLYGON
Definition vtkCellType.h:58
@ VTK_QUAD
Definition vtkCellType.h:45
@ VTK_QUADRATIC_TRIANGLE
Definition vtkCellType.h:56
@ VTK_QUADRATIC_EDGE
Definition vtkCellType.h:55
@ VTK_QUADRATIC_TETRA
Definition vtkCellType.h:59
@ VTK_BEZIER_TETRAHEDRON
@ VTK_VERTEX
Definition vtkCellType.h:37
@ VTK_POLY_VERTEX
Definition vtkCellType.h:38
@ VTK_QUADRATIC_LINEAR_QUAD
Definition vtkCellType.h:66
@ VTK_BIQUADRATIC_QUADRATIC_WEDGE
Definition vtkCellType.h:68
@ VTK_BIQUADRATIC_TRIANGLE
Definition vtkCellType.h:70
#define vtkDataArray
int vtkIdType
Definition vtkType.h:367