Go to the documentation of this file.
53 #ifndef vtk_m_worklet_contourtree_augmented_mesh_dem_mesh_types_mesh_boundary_compute_mesh_boundary_2D_h
54 #define vtk_m_worklet_contourtree_augmented_mesh_dem_mesh_types_mesh_boundary_compute_mesh_boundary_2D_h
63 namespace contourtree_augmented
73 WholeArrayIn sortIndices,
74 ExecObject meshBoundary,
86 template <
typename InFieldPortalType,
typename MeshBoundaryType>
88 const InFieldPortalType sortIndicesPortal,
89 const MeshBoundaryType& meshBoundary,
93 auto meshStructure2D = meshBoundary.GetMeshStructure();
94 vtkm::Id numBoundary = 2 * meshStructure2D.MeshSize[1] + 2 * meshStructure2D.MeshSize[0] - 4;
98 if (boundaryId < meshStructure2D.MeshSize[0])
100 boundaryVertex = meshStructure2D.VertexId(
vtkm::Id2{ boundaryId, 0 });
103 else if (boundaryId > numBoundary - meshStructure2D.MeshSize[0] - 1)
105 boundaryVertex = meshStructure2D.VertexId(
vtkm::Id2{
106 boundaryId + meshStructure2D.MeshSize[0] - numBoundary, meshStructure2D.MeshSize[1] - 1 });
111 boundaryVertex = meshStructure2D.VertexId(
vtkm::Id2{
112 ((boundaryId - meshStructure2D.MeshSize[0]) % 2) ? (meshStructure2D.MeshSize[0] - 1) : 0,
113 ((boundaryId - meshStructure2D.MeshSize[0]) / 2) + 1 });
116 boundarySortIndex = sortIndicesPortal.Get(boundaryVertex);
void ExecutionSignature(_1, _2, _3, _4, _5)
Definition: ComputeMeshBoundary2D.h:78
#define VTKM_EXEC
Definition: ExportMacros.h:51
Groups connected points that have the same field value.
Definition: Atomic.h:19
VTKM_EXEC_CONT ComputeMeshBoundary2D()
Definition: ComputeMeshBoundary2D.h:84
#define VTKM_EXEC_CONT
Definition: ExportMacros.h:52
A control signature tag for output fields.
Definition: WorkletMapField.h:60
void ControlSignature(FieldIn boundaryId, WholeArrayIn sortIndices, ExecObject meshBoundary, FieldOut boundaryVertexArray, FieldOut boundarySortIndexArray)
Definition: ComputeMeshBoundary2D.h:72
vtkm::Int32 Id
Represents an ID (index into arrays).
Definition: Types.h:191
VTKM_EXEC void operator()(const vtkm::Id &boundaryId, const InFieldPortalType sortIndicesPortal, const MeshBoundaryType &meshBoundary, vtkm::Id &boundaryVertex, vtkm::Id &boundarySortIndex) const
Definition: ComputeMeshBoundary2D.h:87
Definition: ComputeMeshBoundary2D.h:69
A control signature tag for input fields.
Definition: WorkletMapField.h:49
_1 InputDomain
Definition: ComputeMeshBoundary2D.h:79
Base class for worklets that do a simple mapping of field arrays.
Definition: WorkletMapField.h:38