VTK  9.3.1
vtkCellTypeSource.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
20 #ifndef vtkCellTypeSource_h
21 #define vtkCellTypeSource_h
22 
23 #include "vtkFiltersSourcesModule.h" // For export macro
25 
26 VTK_ABI_NAMESPACE_BEGIN
27 class vtkMergePoints;
28 
29 class VTKFILTERSSOURCES_EXPORT vtkCellTypeSource : public vtkUnstructuredGridAlgorithm
30 {
31 public:
33 
36  static vtkCellTypeSource* New();
38  void PrintSelf(ostream& os, vtkIndent indent) override;
40 
42 
45  void SetCellType(int cellType);
46  vtkGetMacro(CellType, int);
48 
50 
59  vtkSetMacro(CellOrder, int);
60  vtkGetMacro(CellOrder, int);
62 
64 
83  vtkSetMacro(CompleteQuadraticSimplicialElements, bool);
84  vtkGetMacro(CompleteQuadraticSimplicialElements, bool);
85  vtkBooleanMacro(CompleteQuadraticSimplicialElements, bool);
87 
89 
93  vtkSetClampMacro(PolynomialFieldOrder, int, 0, VTK_INT_MAX);
94  vtkGetMacro(PolynomialFieldOrder, int);
96 
98 
101  int GetCellDimension();
103 
105 
110  vtkSetClampMacro(OutputPrecision, int, 0, 1);
111  vtkGetMacro(OutputPrecision, int);
113 
115 
121  void SetBlocksDimensions(int*);
122  void SetBlocksDimensions(int, int, int);
123  vtkGetVector3Macro(BlocksDimensions, int);
125 
126 protected:
128  ~vtkCellTypeSource() override = default;
129 
132 
133  void GenerateTriangles(vtkUnstructuredGrid*, int extent[6]);
134  void GenerateQuads(vtkUnstructuredGrid*, int extent[6]);
135  void GenerateQuadraticTriangles(vtkUnstructuredGrid*, int extent[6]);
136  void GenerateQuadraticQuads(vtkUnstructuredGrid*, int extent[6]);
137  void GenerateTetras(vtkUnstructuredGrid*, int extent[6]);
138  void GenerateHexahedron(vtkUnstructuredGrid*, int extent[6]);
139  void GenerateWedges(vtkUnstructuredGrid*, int extent[6]);
140  void GeneratePyramids(vtkUnstructuredGrid*, int extent[6]);
141  void GeneratePentagonalPrism(vtkUnstructuredGrid*, int extent[6]);
142  void GenerateHexagonalPrism(vtkUnstructuredGrid*, int extent[6]);
143  void GenerateQuadraticTetras(vtkUnstructuredGrid*, int extent[6]);
144  void GenerateQuadraticHexahedron(vtkUnstructuredGrid*, int extent[6]);
145  void GenerateQuadraticWedges(vtkUnstructuredGrid*, int extent[6]);
146  void GenerateQuadraticPyramids(vtkUnstructuredGrid*, int extent[6]);
147  void GenerateTriQuadraticPyramids(vtkUnstructuredGrid*, int extent[6]);
148 
149  void GenerateLagrangeCurves(vtkUnstructuredGrid*, int extent[6]);
150  void GenerateLagrangeTris(vtkUnstructuredGrid*, int extent[6]);
151  void GenerateLagrangeQuads(vtkUnstructuredGrid*, int extent[6]);
152  void GenerateLagrangeTets(vtkUnstructuredGrid*, int extent[6]);
153  void GenerateLagrangeHexes(vtkUnstructuredGrid*, int extent[6]);
154  void GenerateLagrangeWedges(vtkUnstructuredGrid*, int extent[6]);
155 
156  void GenerateBezierCurves(vtkUnstructuredGrid*, int extent[6]);
157  void GenerateBezierTris(vtkUnstructuredGrid*, int extent[6]);
158  void GenerateBezierQuads(vtkUnstructuredGrid*, int extent[6]);
159  void GenerateBezierTets(vtkUnstructuredGrid*, int extent[6]);
160  void GenerateBezierHexes(vtkUnstructuredGrid*, int extent[6]);
161  void GenerateBezierWedges(vtkUnstructuredGrid*, int extent[6]);
162 
163  virtual void ComputeFields(vtkUnstructuredGrid*);
164  double GetValueOfOrder(int order, double coords[3]);
165 
166  int BlocksDimensions[3];
167  int CellType;
172  vtkMergePoints* Locator; // Only valid during RequestData.
173 
174 private:
175  vtkCellTypeSource(const vtkCellTypeSource&) = delete;
176  void operator=(const vtkCellTypeSource&) = delete;
177 };
178 
179 VTK_ABI_NAMESPACE_END
180 #endif
vtkMergePoints * Locator
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
Store vtkAlgorithm input/output information.
#define VTK_INT_MAX
Definition: vtkType.h:144
static vtkUnstructuredGridAlgorithm * New()
virtual int RequestInformation(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
bool CompleteQuadraticSimplicialElements
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
a simple class to control print indentation
Definition: vtkIndent.h:28
merge exactly coincident points
dataset represents arbitrary combinations of all possible cell types
Superclass for algorithms that produce only unstructured grid as output.
Create cells of a given type.
Store zero or more vtkInformation instances.