VTK  9.7.1
vtkDGVert.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
12 #ifndef vtkDGVert_h
13 #define vtkDGVert_h
14 
15 #include "vtkFiltersCellGridModule.h" // for export macro
16 
17 #include "vtkDGCell.h"
18 #include "vtkStringToken.h" // for vtkStringToken::Hash
19 
20 VTK_ABI_NAMESPACE_BEGIN
21 class vtkCellGrid;
23 class vtkCellAttribute;
24 
25 class VTKFILTERSCELLGRID_EXPORT vtkDGVert : public vtkDGCell
26 {
27 public:
28  static vtkDGVert* New();
29 
30  vtkTypeMacro(vtkDGVert, vtkDGCell);
32  void PrintSelf(ostream& os, vtkIndent indent) override;
33 
40  double GetSignedParametricDistance(const vtkVector3d& rst) const override;
41  Shape GetShape() const override { return Shape::Vertex; }
42  int GetDimension() const override { return Dimension; }
43  const std::array<double, 3>& GetCornerParameter(int corner) const override;
44  int GetNumberOfSideTypes() const override;
45  std::pair<int, int> GetSideRangeForType(int sideType) const override;
46  int GetNumberOfSidesOfDimension(int dimension) const override;
47  const std::vector<vtkIdType>& GetSideConnectivity(int side) const override;
48  const std::vector<vtkIdType>& GetSidesOfSide(int side) const override;
49  Shape GetSideShape(int side) const override;
50 
51  vtkTypeFloat32Array* GetReferencePoints() const override;
52  vtkTypeInt32Array* GetSideConnectivity() const override;
53  vtkTypeInt32Array* GetSideOffsetsAndShapes() const override;
55 
56  static constexpr int Dimension = 0;
57  static const std::array<std::array<double, 3>, 1> Parameters;
58  static const std::array<std::vector<vtkIdType>, 1> Sides;
59  static const std::array<std::vector<vtkIdType>, 1> SidesOfSides;
60  static const std::array<int, Dimension + 2> SideOffsets;
61  static const std::array<Shape, Dimension + 2> SideShapes;
62 
63 protected:
64  vtkDGVert();
65  ~vtkDGVert() override;
66 
67 private:
68  vtkDGVert(const vtkDGVert&) = delete;
69  void operator=(const vtkDGVert&) = delete;
70 };
71 
72 VTK_ABI_NAMESPACE_END
73 #endif
virtual std::pair< int, int > GetSideRangeForType(int sideType) const =0
Return the range of sides of the ii-th type, where ii is in [-2, this->GetNumberOfSideTypes()[.
int GetDimension() const override
Definition: vtkDGVert.h:42
virtual double GetSignedParametricDistance(const vtkVector3d &rst) const =0
Return the signed parametric distance of rst from the reference element boundary. ...
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
virtual int GetNumberOfSidesOfDimension(int dimension) const =0
Return the number of boundaries this type of cell has of a given dimension.
RealT rst
Definition: TetF2Basis.h:17
virtual vtkTypeInt32Array * GetSideOffsetsAndShapes() const =0
Return a singleton array initialized with 2-tuples of (offset, shape) values.
Visualization data composed of cells of arbitrary type.
Definition: vtkCellGrid.h:48
static const std::array< Shape, Dimension+2 > SideShapes
Definition: vtkDGVert.h:61
virtual vtkTypeInt32Array * GetSideConnectivity() const =0
Return a singleton array initialized with point-ids of each side's corners.
a simple class to control print indentation
Definition: vtkIndent.h:28
A function defined over the physical domain of a vtkCellGrid.
virtual Shape GetSideShape(int side) const =0
For a given side, return its cell shape.
static const std::array< std::vector< vtkIdType >, 1 > Sides
Definition: vtkDGVert.h:58
static const std::array< int, Dimension+2 > SideOffsets
Definition: vtkDGVert.h:60
virtual int GetNumberOfSideTypes() const =0
Return the number of different side shapes of this cell type.
Base class for a discontinuous Galerkin cells of all shapes.
Definition: vtkDGCell.h:43
represent and manipulate attribute data in a dataset
Metadata for a discontinuous Galerkin vertex.
Definition: vtkDGVert.h:25
vtkInheritanceHierarchyOverrideMacro(vtkDGCell)
static const std::array< std::vector< vtkIdType >, 1 > SidesOfSides
Definition: vtkDGVert.h:59
virtual const std::vector< vtkIdType > & GetSidesOfSide(int side) const =0
Return a vector of side IDs given an input side ID.
static const std::array< std::array< double, 3 >, 1 > Parameters
Definition: vtkDGVert.h:57
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
virtual const std::array< double, 3 > & GetCornerParameter(int corner) const =0
Return the coordinates of the reference element's corner vertex.
virtual vtkTypeFloat32Array * GetReferencePoints() const =0
Return a singleton array initialized with the reference-cell's corner point coordinates.
Shape
All possible shapes for DG cells.
Definition: vtkDGCell.h:70
Shape GetShape() const override
Definition: vtkDGVert.h:41