1#ifndef UNSTRUCTUREDGRID_H
2#define UNSTRUCTUREDGRID_H
40 static const Index MaxNumVertices = 4;
41 static const Index MaxNumFaces = 6;
46 static const unsigned FaceSizes[
NUM_TYPES][MaxNumFaces];
47 static const unsigned FaceVertices[
NUM_TYPES][MaxNumFaces][MaxNumVertices];
52 void resetElements()
override;
55 const Byte *
tl()
const {
return m_tl; }
57 bool isConvex(
Index elem)
const;
58 bool isGhostCell(
Index elem)
const override;
59 std::pair<Vector, Vector> cellBounds(
Index elem)
const override;
61 bool insideConvex(
Index elem,
const Vector &point)
const;
62 bool inside(
Index elem,
const Vector &point)
const override;
63 Index checkConvexity();
66 Interpolator getInterpolator(
Index elem,
const Vector &point, Mapping mapping = Vertex,
67 InterpolationMode mode = Linear)
const override;
68 std::pair<Vector, Vector> elementBounds(
Index elem)
const override;
69 std::vector<Index> cellVertices(
Index elem)
const override;
72 std::vector<Index> getNeighborElements(
Index elem)
const override;
76 mutable const Byte *m_tl;
81 Data(
const Index numElements = 0,
const Index numCorners = 0,
const Index numVertices = 0,
82 const std::string &name =
"",
const Meta &meta =
Meta());
83 static Data *create(
const Index numElements = 0,
const Index numCorners = 0,
const Index numVertices = 0,
Type
Definition: object.h:84
Indexed Base
Definition: unstr.h:17
shm< Byte >::array & tl()
Definition: unstr.h:54
const Byte * tl() const
Definition: unstr.h:55
Definition: shm_reference.h:15
Definition: shm_array.h:19
#define V_COREEXPORT
Definition: export.h:9
@ NUM_TYPES
Definition: celltypes.h:32
@ NONE
Definition: celltypes.h:19
@ TRIANGLE
Definition: celltypes.h:21
@ POLYHEDRON
Definition: celltypes.h:31
@ BAR
Definition: celltypes.h:20
@ HEXAHEDRON
Definition: celltypes.h:26
@ VPOLYHEDRON
Definition: celltypes.h:27
@ PRISM
Definition: celltypes.h:25
@ PYRAMID
Definition: celltypes.h:24
@ TETRAHEDRON
Definition: celltypes.h:23
@ CONVEX_BIT
Definition: celltypes.h:15
@ TYPE_MASK
Definition: celltypes.h:16
@ CPOLYHEDRON
Definition: celltypes.h:30
@ QUAD
Definition: celltypes.h:22
@ POLYGON
Definition: celltypes.h:28
@ POINT
Definition: celltypes.h:29
@ GHOST_BIT
Definition: celltypes.h:14
Definition: allobjects.cpp:30
unsigned char Byte
Definition: scalar.h:9
Vector3 Vector
Definition: vector.h:36
const Index InvalidIndex
Definition: index.h:17
float Scalar
Definition: scalar.h:14
uint32_t Index
Definition: index.h:13
#define V_DATA_BEGIN(ObjType)
Definition: object.h:474
#define V_DATA_END(ObjType)
Definition: object.h:481
#define V_OBJECT(ObjType)
declare a new Object type
Definition: object.h:381