VTK-m  2.0
Cylinderizer.h
Go to the documentation of this file.
1 //============================================================================
2 // Copyright (c) Kitware, Inc.
3 // All rights reserved.
4 // See LICENSE.txt for details.
5 //
6 // This software is distributed WITHOUT ANY WARRANTY; without even
7 // the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
8 // PURPOSE. See the above copyright notice for more information.
9 //============================================================================
10 #ifndef vtk_m_rendering_Cylinderizer_h
11 #define vtk_m_rendering_Cylinderizer_h
12 
13 #include <typeinfo>
14 #include <vtkm/cont/Algorithm.h>
17 #include <vtkm/cont/DataSet.h>
23 
24 #define SEG_PER_TRI 3
25 //CSS is CellSetStructured
26 #define TRI_PER_CSS 12
27 
28 namespace vtkm
29 {
30 namespace rendering
31 {
32 
34 {
35 public:
37  {
38  public:
39  VTKM_CONT
41  typedef void ControlSignature(CellSetIn cellset, FieldOut);
42  typedef void ExecutionSignature(CellShape, _2);
43 
44  VTKM_EXEC
45  void operator()(vtkm::CellShapeTagGeneric shapeType, vtkm::Id& segments) const
46  {
47  if (shapeType.Id == vtkm::CELL_SHAPE_LINE)
48  segments = 1;
49  else if (shapeType.Id == vtkm::CELL_SHAPE_TRIANGLE)
50  segments = 3;
51  else if (shapeType.Id == vtkm::CELL_SHAPE_QUAD)
52  segments = 4;
53  else if (shapeType.Id == vtkm::CELL_SHAPE_TETRA)
54  segments = 12;
55  else if (shapeType.Id == vtkm::CELL_SHAPE_WEDGE)
56  segments = 24;
57  else if (shapeType.Id == vtkm::CELL_SHAPE_PYRAMID)
58  segments = 18;
59  else if (shapeType.Id == vtkm::CELL_SHAPE_HEXAHEDRON)
60  segments = 36;
61  else
62  segments = 0;
63  }
64 
65  VTKM_EXEC
66  void operator()(vtkm::CellShapeTagHexahedron vtkmNotUsed(shapeType), vtkm::Id& segments) const
67  {
68  segments = 36;
69  }
70 
71  VTKM_EXEC
72  void operator()(vtkm::CellShapeTagQuad vtkmNotUsed(shapeType), vtkm::Id& segments) const
73  {
74  segments = 4;
75  }
76  VTKM_EXEC
77  void operator()(vtkm::CellShapeTagWedge vtkmNotUsed(shapeType), vtkm::Id& segments) const
78  {
79  segments = 24;
80  }
81  }; //class CountSegments
82 
83  template <int DIM>
85  {
86 
87  public:
88  typedef void ControlSignature(CellSetIn cellset, FieldInCell, WholeArrayOut);
89  typedef void ExecutionSignature(IncidentElementIndices, _2, _3);
90  //typedef _1 InputDomain;
91  VTKM_CONT
93 
94 #if defined(VTKM_MSVC)
95 #pragma warning(push)
96 #pragma warning(disable : 4127) //conditional expression is constant
97 #endif
98  template <typename CellNodeVecType, typename OutIndicesPortal>
100  vtkm::Vec<Id, 3>& segment,
101  const vtkm::Id offset,
102  const CellNodeVecType& cellIndices,
103  OutIndicesPortal& outputIndices) const
104  {
105 
106  segment[1] = cellIndices[vtkm::IdComponent(idx[0])];
107  segment[2] = cellIndices[vtkm::IdComponent(idx[1])];
108  outputIndices.Set(offset, segment);
109 
110  segment[1] = cellIndices[vtkm::IdComponent(idx[1])];
111  segment[2] = cellIndices[vtkm::IdComponent(idx[2])];
112  outputIndices.Set(offset + 1, segment);
113 
114  segment[1] = cellIndices[vtkm::IdComponent(idx[2])];
115  segment[2] = cellIndices[vtkm::IdComponent(idx[0])];
116  outputIndices.Set(offset + 2, segment);
117  }
118  template <typename CellNodeVecType, typename OutIndicesPortal>
119  VTKM_EXEC void operator()(const CellNodeVecType& cellIndices,
120  const vtkm::Id& cellIndex,
121  OutIndicesPortal& outputIndices) const
122  {
123  if (DIM == 2)
124  {
125  // Do nothing mark says
126  }
127  else if (DIM == 3)
128  {
129  vtkm::Id offset = cellIndex * TRI_PER_CSS * SEG_PER_TRI;
130  vtkm::Id3 segment;
131  segment[0] = cellIndex;
132  vtkm::Id3 idx;
133  idx[0] = 0;
134  idx[1] = 1;
135  idx[2] = 5;
136  cell2seg(idx, segment, offset, cellIndices, outputIndices);
137  idx[0] = 0;
138  idx[1] = 5;
139  idx[2] = 4;
140  offset += 3;
141  cell2seg(idx, segment, offset, cellIndices, outputIndices);
142  idx[0] = 1;
143  idx[1] = 2;
144  idx[2] = 6;
145  offset += 3;
146  cell2seg(idx, segment, offset, cellIndices, outputIndices);
147  idx[0] = 1;
148  idx[1] = 6;
149  idx[2] = 5;
150  offset += 3;
151  cell2seg(idx, segment, offset, cellIndices, outputIndices);
152  idx[0] = 3;
153  idx[1] = 7;
154  idx[2] = 6;
155  offset += 3;
156  cell2seg(idx, segment, offset, cellIndices, outputIndices);
157  idx[0] = 3;
158  idx[1] = 6;
159  idx[2] = 2;
160  offset += 3;
161  cell2seg(idx, segment, offset, cellIndices, outputIndices);
162  idx[0] = 0;
163  idx[1] = 4;
164  idx[2] = 7;
165  offset += 3;
166  cell2seg(idx, segment, offset, cellIndices, outputIndices);
167  idx[0] = 0;
168  idx[1] = 7;
169  idx[2] = 3;
170  offset += 3;
171  cell2seg(idx, segment, offset, cellIndices, outputIndices);
172  idx[0] = 0;
173  idx[1] = 3;
174  idx[2] = 2;
175  offset += 3;
176  cell2seg(idx, segment, offset, cellIndices, outputIndices);
177  idx[0] = 0;
178  idx[1] = 2;
179  idx[2] = 1;
180  offset += 3;
181  cell2seg(idx, segment, offset, cellIndices, outputIndices);
182  idx[0] = 4;
183  idx[1] = 5;
184  idx[2] = 6;
185  offset += 3;
186  cell2seg(idx, segment, offset, cellIndices, outputIndices);
187  idx[0] = 4;
188  idx[1] = 6;
189  idx[2] = 7;
190  offset += 3;
191  cell2seg(idx, segment, offset, cellIndices, outputIndices);
192  }
193  }
194 #if defined(VTKM_MSVC)
195 #pragma warning(pop)
196 #endif
197  };
198 
199 
201  {
202 
203  public:
204  VTKM_CONT
206  typedef void ControlSignature(CellSetIn cellset, FieldInCell, WholeArrayOut);
207  typedef void ExecutionSignature(_2, CellShape, PointIndices, WorkIndex, _3);
208 
209  template <typename VecType, typename OutputPortal>
210  VTKM_EXEC void tri2seg(vtkm::Id& offset,
211  const VecType& cellIndices,
212  const vtkm::Id& cellId,
213  const vtkm::Id Id0,
214  const vtkm::Id Id1,
215  const vtkm::Id Id2,
216  OutputPortal& outputIndices) const
217  {
218  vtkm::Id3 segment;
219  segment[0] = cellId;
220  segment[1] = vtkm::Id(cellIndices[vtkm::IdComponent(Id0)]);
221  segment[2] = vtkm::Id(cellIndices[vtkm::IdComponent(Id1)]);
222  outputIndices.Set(offset++, segment);
223 
224  segment[1] = vtkm::Id(cellIndices[vtkm::IdComponent(Id1)]);
225  segment[2] = vtkm::Id(cellIndices[vtkm::IdComponent(Id2)]);
226  outputIndices.Set(offset++, segment);
227 
228  segment[1] = vtkm::Id(cellIndices[vtkm::IdComponent(Id2)]);
229  segment[2] = vtkm::Id(cellIndices[vtkm::IdComponent(Id0)]);
230  outputIndices.Set(offset++, segment);
231  }
232 
233 
234  template <typename VecType, typename OutputPortal>
235  VTKM_EXEC void operator()(const vtkm::Id& offset,
236  vtkm::CellShapeTagQuad shapeType,
237  const VecType& cellIndices,
238  const vtkm::Id& cellId,
239  OutputPortal& outputIndices) const
240  {
241  if (shapeType.Id == vtkm::CELL_SHAPE_QUAD)
242  {
243  vtkm::Id3 segment;
244  segment[0] = cellId;
245  segment[1] = cellIndices[0];
246  segment[2] = cellIndices[1];
247  outputIndices.Set(offset, segment);
248 
249  segment[1] = cellIndices[1];
250  segment[2] = cellIndices[2];
251  outputIndices.Set(offset + 1, segment);
252 
253  segment[1] = cellIndices[2];
254  segment[2] = cellIndices[3];
255  outputIndices.Set(offset + 2, segment);
256 
257  segment[1] = cellIndices[3];
258  segment[2] = cellIndices[0];
259  outputIndices.Set(offset + 3, segment);
260  }
261  }
262 
263  template <typename VecType, typename OutputPortal>
264  VTKM_EXEC void operator()(const vtkm::Id& pointOffset,
265  vtkm::CellShapeTagHexahedron vtkmNotUsed(shapeType),
266  const VecType& cellIndices,
267  const vtkm::Id& cellId,
268  OutputPortal& outputIndices) const
269 
270  {
271  vtkm::Id offset = pointOffset;
272  tri2seg(offset, cellIndices, cellId, 0, 1, 5, outputIndices);
273  tri2seg(offset, cellIndices, cellId, 0, 5, 4, outputIndices);
274  tri2seg(offset, cellIndices, cellId, 1, 2, 6, outputIndices);
275  tri2seg(offset, cellIndices, cellId, 1, 6, 5, outputIndices);
276  tri2seg(offset, cellIndices, cellId, 3, 7, 6, outputIndices);
277  tri2seg(offset, cellIndices, cellId, 3, 6, 2, outputIndices);
278  tri2seg(offset, cellIndices, cellId, 0, 4, 7, outputIndices);
279  tri2seg(offset, cellIndices, cellId, 0, 7, 3, outputIndices);
280  tri2seg(offset, cellIndices, cellId, 0, 3, 2, outputIndices);
281  tri2seg(offset, cellIndices, cellId, 0, 2, 1, outputIndices);
282  tri2seg(offset, cellIndices, cellId, 4, 5, 6, outputIndices);
283  tri2seg(offset, cellIndices, cellId, 4, 6, 7, outputIndices);
284  }
285  template <typename VecType, typename OutputPortal>
286  VTKM_EXEC void operator()(const vtkm::Id& pointOffset,
287  vtkm::CellShapeTagWedge vtkmNotUsed(shapeType),
288  const VecType& cellIndices,
289  const vtkm::Id& cellId,
290  OutputPortal& outputIndices) const
291 
292  {
293  vtkm::Id offset = pointOffset;
294  tri2seg(offset, cellIndices, cellId, 0, 1, 2, outputIndices);
295  tri2seg(offset, cellIndices, cellId, 3, 5, 4, outputIndices);
296  tri2seg(offset, cellIndices, cellId, 3, 0, 2, outputIndices);
297  tri2seg(offset, cellIndices, cellId, 3, 2, 5, outputIndices);
298  tri2seg(offset, cellIndices, cellId, 1, 4, 5, outputIndices);
299  tri2seg(offset, cellIndices, cellId, 1, 5, 2, outputIndices);
300  tri2seg(offset, cellIndices, cellId, 0, 3, 4, outputIndices);
301  tri2seg(offset, cellIndices, cellId, 0, 4, 1, outputIndices);
302  }
303  template <typename VecType, typename OutputPortal>
304  VTKM_EXEC void operator()(const vtkm::Id& pointOffset,
305  vtkm::CellShapeTagGeneric shapeType,
306  const VecType& cellIndices,
307  const vtkm::Id& cellId,
308  OutputPortal& outputIndices) const
309  {
310 
311  if (shapeType.Id == vtkm::CELL_SHAPE_LINE)
312  {
313  vtkm::Id3 segment;
314  segment[0] = cellId;
315 
316  segment[1] = cellIndices[0];
317  segment[2] = cellIndices[1];
318  outputIndices.Set(pointOffset, segment);
319  }
320  if (shapeType.Id == vtkm::CELL_SHAPE_TRIANGLE)
321  {
322  vtkm::Id3 segment;
323  segment[0] = cellId;
324  segment[1] = cellIndices[0];
325  segment[2] = cellIndices[1];
326  outputIndices.Set(pointOffset, segment);
327 
328  segment[1] = cellIndices[1];
329  segment[2] = cellIndices[2];
330  outputIndices.Set(pointOffset + 1, segment);
331 
332  segment[1] = cellIndices[2];
333  segment[2] = cellIndices[0];
334  outputIndices.Set(pointOffset + 2, segment);
335  }
336  if (shapeType.Id == vtkm::CELL_SHAPE_QUAD)
337  {
338  vtkm::Id3 segment;
339  segment[0] = cellId;
340  segment[1] = cellIndices[0];
341  segment[2] = cellIndices[1];
342  outputIndices.Set(pointOffset, segment);
343 
344  segment[1] = cellIndices[1];
345  segment[2] = cellIndices[2];
346  outputIndices.Set(pointOffset + 1, segment);
347 
348  segment[1] = cellIndices[2];
349  segment[2] = cellIndices[3];
350  outputIndices.Set(pointOffset + 2, segment);
351 
352  segment[1] = cellIndices[3];
353  segment[2] = cellIndices[0];
354  outputIndices.Set(pointOffset + 3, segment);
355  }
356  if (shapeType.Id == vtkm::CELL_SHAPE_TETRA)
357  {
358  vtkm::Id offset = pointOffset;
359  tri2seg(offset, cellIndices, cellId, 0, 3, 1, outputIndices);
360  tri2seg(offset, cellIndices, cellId, 1, 2, 3, outputIndices);
361  tri2seg(offset, cellIndices, cellId, 0, 2, 3, outputIndices);
362  tri2seg(offset, cellIndices, cellId, 0, 2, 1, outputIndices);
363  }
364  if (shapeType.Id == vtkm::CELL_SHAPE_HEXAHEDRON)
365  {
366  vtkm::Id offset = pointOffset;
367  tri2seg(offset, cellIndices, cellId, 0, 1, 5, outputIndices);
368  tri2seg(offset, cellIndices, cellId, 0, 5, 4, outputIndices);
369  tri2seg(offset, cellIndices, cellId, 1, 2, 6, outputIndices);
370  tri2seg(offset, cellIndices, cellId, 1, 6, 5, outputIndices);
371  tri2seg(offset, cellIndices, cellId, 3, 7, 6, outputIndices);
372  tri2seg(offset, cellIndices, cellId, 3, 6, 2, outputIndices);
373  tri2seg(offset, cellIndices, cellId, 0, 4, 7, outputIndices);
374  tri2seg(offset, cellIndices, cellId, 0, 7, 3, outputIndices);
375  tri2seg(offset, cellIndices, cellId, 0, 3, 2, outputIndices);
376  tri2seg(offset, cellIndices, cellId, 0, 2, 1, outputIndices);
377  tri2seg(offset, cellIndices, cellId, 4, 5, 6, outputIndices);
378  tri2seg(offset, cellIndices, cellId, 4, 6, 7, outputIndices);
379  }
380  if (shapeType.Id == vtkm::CELL_SHAPE_WEDGE)
381  {
382  vtkm::Id offset = pointOffset;
383  tri2seg(offset, cellIndices, cellId, 0, 1, 2, outputIndices);
384  tri2seg(offset, cellIndices, cellId, 3, 5, 4, outputIndices);
385  tri2seg(offset, cellIndices, cellId, 3, 0, 2, outputIndices);
386  tri2seg(offset, cellIndices, cellId, 3, 2, 5, outputIndices);
387  tri2seg(offset, cellIndices, cellId, 1, 4, 5, outputIndices);
388  tri2seg(offset, cellIndices, cellId, 1, 5, 2, outputIndices);
389  tri2seg(offset, cellIndices, cellId, 0, 3, 4, outputIndices);
390  tri2seg(offset, cellIndices, cellId, 0, 4, 1, outputIndices);
391  }
392  if (shapeType.Id == vtkm::CELL_SHAPE_PYRAMID)
393  {
394  vtkm::Id offset = pointOffset;
395 
396  tri2seg(offset, cellIndices, cellId, 0, 4, 1, outputIndices);
397  tri2seg(offset, cellIndices, cellId, 1, 2, 4, outputIndices);
398  tri2seg(offset, cellIndices, cellId, 2, 3, 4, outputIndices);
399  tri2seg(offset, cellIndices, cellId, 0, 4, 3, outputIndices);
400  tri2seg(offset, cellIndices, cellId, 3, 2, 1, outputIndices);
401  tri2seg(offset, cellIndices, cellId, 3, 1, 0, outputIndices);
402  }
403  }
404 
405  }; //class cylinderize
406 
407 public:
408  VTKM_CONT
410 
411  VTKM_CONT
412  void Run(const vtkm::cont::UnknownCellSet& cellset,
413  vtkm::cont::ArrayHandle<vtkm::Id3>& outputIndices,
414  vtkm::Id& output)
415  {
417  {
418  vtkm::cont::CellSetStructured<3> cellSetStructured3D =
420  const vtkm::Id numCells = cellSetStructured3D.GetNumberOfCells();
421 
422  vtkm::cont::ArrayHandleCounting<vtkm::Id> cellIdxs(0, 1, numCells);
423  outputIndices.Allocate(numCells * TRI_PER_CSS * SEG_PER_TRI);
424 
426  segInvoker.Invoke(cellSetStructured3D, cellIdxs, outputIndices);
427 
428  output = numCells * TRI_PER_CSS * SEG_PER_TRI;
429  }
430  else
431  {
432  auto cellSetUnstructured =
433  cellset.ResetCellSetList(VTKM_DEFAULT_CELL_SET_LIST_UNSTRUCTURED{});
434 
435  vtkm::cont::ArrayHandle<vtkm::Id> segmentsPerCell;
437  countInvoker.Invoke(cellSetUnstructured, segmentsPerCell);
438 
439  vtkm::Id total = 0;
440  total = vtkm::cont::Algorithm::Reduce(segmentsPerCell, vtkm::Id(0));
441 
443  vtkm::cont::Algorithm::ScanExclusive(segmentsPerCell, cellOffsets);
444  outputIndices.Allocate(total);
445 
447  cylInvoker.Invoke(cellSetUnstructured, cellOffsets, outputIndices);
448 
449  output = total;
450  }
451  }
452 };
453 }
454 }
455 #endif
vtkm::rendering::Cylinderizer::SegmentedStructured::cell2seg
VTKM_EXEC void cell2seg(vtkm::Id3 idx, vtkm::Vec< Id, 3 > &segment, const vtkm::Id offset, const CellNodeVecType &cellIndices, OutIndicesPortal &outputIndices) const
Definition: Cylinderizer.h:99
vtkm::rendering::Cylinderizer::CountSegments::operator()
VTKM_EXEC void operator()(vtkm::CellShapeTagGeneric shapeType, vtkm::Id &segments) const
Definition: Cylinderizer.h:45
vtkm::cont::ArrayHandle
Manages an array-worth of data.
Definition: ArrayHandle.h:283
vtkm::rendering::Cylinderizer::Cylinderize::operator()
VTKM_EXEC void operator()(const vtkm::Id &pointOffset, vtkm::CellShapeTagHexahedron vtkmNotUsed(shapeType), const VecType &cellIndices, const vtkm::Id &cellId, OutputPortal &outputIndices) const
Definition: Cylinderizer.h:264
vtkm::CELL_SHAPE_WEDGE
@ CELL_SHAPE_WEDGE
Definition: CellShape.h:49
vtkm::cont::CellSetStructured::GetNumberOfCells
vtkm::Id GetNumberOfCells() const override
Definition: CellSetStructured.h:38
VTKM_EXEC
#define VTKM_EXEC
Definition: ExportMacros.h:51
vtkm
Groups connected points that have the same field value.
Definition: Atomic.h:19
vtkm::rendering::Cylinderizer::CountSegments::CountSegments
VTKM_CONT CountSegments()
Definition: Cylinderizer.h:40
vtkm::rendering::Cylinderizer::SegmentedStructured::operator()
VTKM_EXEC void operator()(const CellNodeVecType &cellIndices, const vtkm::Id &cellIndex, OutIndicesPortal &outputIndices) const
Definition: Cylinderizer.h:119
WorkletMapField.h
vtkm::cont::UnknownCellSet::CanConvert
VTKM_CONT bool CanConvert() const
Returns true if this cell set can be retrieved as the given type.
Definition: UnknownCellSet.h:161
vtkm::cont::ArrayHandle::Allocate
VTKM_CONT void Allocate(vtkm::Id numberOfValues, vtkm::CopyFlag preserve, vtkm::cont::Token &token) const
Allocates an array large enough to hold the given number of values.
Definition: ArrayHandle.h:465
vtkm::IdComponent
vtkm::Int32 IdComponent
Represents a component ID (index of component in a vector).
Definition: Types.h:168
vtkm::cont::CellSetStructured< 3 >
vtkm::rendering::Cylinderizer::Cylinderize
Definition: Cylinderizer.h:200
vtkm::rendering::Cylinderizer::CountSegments::ExecutionSignature
void ExecutionSignature(CellShape, _2)
Definition: Cylinderizer.h:42
vtkm::rendering::Cylinderizer::Cylinderize::ExecutionSignature
void ExecutionSignature(_2, CellShape, PointIndices, WorkIndex, _3)
Definition: Cylinderizer.h:207
vtkm::cont::UnknownCellSet::ResetCellSetList
VTKM_CONT vtkm::cont::UncertainCellSet< CellSetList > ResetCellSetList(CellSetList) const
Assigns potential cell set types.
vtkm::rendering::Cylinderizer::Cylinderize::tri2seg
VTKM_EXEC void tri2seg(vtkm::Id &offset, const VecType &cellIndices, const vtkm::Id &cellId, const vtkm::Id Id0, const vtkm::Id Id1, const vtkm::Id Id2, OutputPortal &outputIndices) const
Definition: Cylinderizer.h:210
TRI_PER_CSS
#define TRI_PER_CSS
Definition: Cylinderizer.h:26
vtkm::cont::UnknownCellSet
A CellSet of an unknown type.
Definition: UnknownCellSet.h:48
vtkm::rendering::Cylinderizer::CountSegments::operator()
VTKM_EXEC void operator()(vtkm::CellShapeTagHexahedron vtkmNotUsed(shapeType), vtkm::Id &segments) const
Definition: Cylinderizer.h:66
UncertainCellSet.h
vtkm::worklet::WorkletVisitCellsWithPoints::PointIndices
IncidentElementIndices PointIndices
Definition: WorkletMapTopology.h:269
vtkm::Id
vtkm::Int32 Id
Represents an ID (index into arrays).
Definition: Types.h:191
vtkm::rendering::Cylinderizer::SegmentedStructured
Definition: Cylinderizer.h:84
vtkm::rendering::Cylinderizer::CountSegments::operator()
VTKM_EXEC void operator()(vtkm::CellShapeTagQuad vtkmNotUsed(shapeType), vtkm::Id &segments) const
Definition: Cylinderizer.h:72
MeshConnectivityBuilder.h
vtkm::cont::UnknownCellSet::AsCellSet
VTKM_CONT void AsCellSet(CellSetType &cellSet) const
Get the cell set as a known type.
Definition: UnknownCellSet.h:178
vtkm::rendering::Cylinderizer::SegmentedStructured::ExecutionSignature
void ExecutionSignature(IncidentElementIndices, _2, _3)
Definition: Cylinderizer.h:89
vtkm::rendering::Cylinderizer::Cylinderizer
VTKM_CONT Cylinderizer()
Definition: Cylinderizer.h:409
vtkm::rendering::Cylinderizer::SegmentedStructured::ControlSignature
void ControlSignature(CellSetIn cellset, FieldInCell, WholeArrayOut)
Definition: Cylinderizer.h:88
vtkm::rendering::Cylinderizer::SegmentedStructured::SegmentedStructured
VTKM_CONT SegmentedStructured()
Definition: Cylinderizer.h:92
vtkm::rendering::Cylinderizer::CountSegments
Definition: Cylinderizer.h:36
Algorithm.h
vtkm::worklet::DispatcherMapTopology
Dispatcher for worklets that inherit from WorkletMapTopology.
Definition: DispatcherMapTopology.h:31
vtkm::cont::Algorithm::ScanExclusive
static VTKM_CONT T ScanExclusive(vtkm::cont::DeviceAdapterId devId, const vtkm::cont::ArrayHandle< T, CIn > &input, vtkm::cont::ArrayHandle< T, COut > &output)
Definition: Algorithm.h:816
vtkm::cont::ArrayHandleCounting< vtkm::Id >
vtkm::CELL_SHAPE_TETRA
@ CELL_SHAPE_TETRA
Definition: CellShape.h:46
vtkm::worklet::WorkletVisitCellsWithPoints
Base class for worklets that map from Points to Cells.
Definition: WorkletMapTopology.h:255
vtkm::rendering::Cylinderizer::Cylinderize::Cylinderize
VTKM_CONT Cylinderize()
Definition: Cylinderizer.h:205
vtkm::rendering::Cylinderizer::Cylinderize::operator()
VTKM_EXEC void operator()(const vtkm::Id &offset, vtkm::CellShapeTagQuad shapeType, const VecType &cellIndices, const vtkm::Id &cellId, OutputPortal &outputIndices) const
Definition: Cylinderizer.h:235
vtkm::rendering::Cylinderizer::Run
VTKM_CONT void Run(const vtkm::cont::UnknownCellSet &cellset, vtkm::cont::ArrayHandle< vtkm::Id3 > &outputIndices, vtkm::Id &output)
Definition: Cylinderizer.h:412
vtkm::rendering::Cylinderizer::Cylinderize::ControlSignature
void ControlSignature(CellSetIn cellset, FieldInCell, WholeArrayOut)
Definition: Cylinderizer.h:206
SEG_PER_TRI
#define SEG_PER_TRI
Definition: Cylinderizer.h:24
VTKM_CONT
#define VTKM_CONT
Definition: ExportMacros.h:57
vtkm::CELL_SHAPE_HEXAHEDRON
@ CELL_SHAPE_HEXAHEDRON
Definition: CellShape.h:48
vtkm::rendering::Cylinderizer
Definition: Cylinderizer.h:33
vtkmNotUsed
#define vtkmNotUsed(parameter_name)
Simple macro to identify a parameter as unused.
Definition: ExportMacros.h:128
vtkm::CELL_SHAPE_TRIANGLE
@ CELL_SHAPE_TRIANGLE
Definition: CellShape.h:41
vtkm::CELL_SHAPE_LINE
@ CELL_SHAPE_LINE
Definition: CellShape.h:39
CellSetPermutation.h
vtkm::rendering::Cylinderizer::CountSegments::ControlSignature
void ControlSignature(CellSetIn cellset, FieldOut)
Definition: Cylinderizer.h:41
vtkm::rendering::Cylinderizer::Cylinderize::operator()
VTKM_EXEC void operator()(const vtkm::Id &pointOffset, vtkm::CellShapeTagGeneric shapeType, const VecType &cellIndices, const vtkm::Id &cellId, OutputPortal &outputIndices) const
Definition: Cylinderizer.h:304
vtkm::Vec< vtkm::Id, 3 >
vtkm::CellShapeTagGeneric::Id
vtkm::UInt8 Id
Definition: CellShape.h:160
vtkm::cont::Algorithm::Reduce
static VTKM_CONT U Reduce(vtkm::cont::DeviceAdapterId devId, const vtkm::cont::ArrayHandle< T, CIn > &input, U initialValue)
Definition: Algorithm.h:656
ArrayHandleCounting.h
vtkm::rendering::Cylinderizer::CountSegments::operator()
VTKM_EXEC void operator()(vtkm::CellShapeTagWedge vtkmNotUsed(shapeType), vtkm::Id &segments) const
Definition: Cylinderizer.h:77
vtkm::CellShapeTagGeneric
A special cell shape tag that holds a cell shape that is not known at compile time.
Definition: CellShape.h:152
vtkm::CELL_SHAPE_PYRAMID
@ CELL_SHAPE_PYRAMID
Definition: CellShape.h:50
DispatcherMapTopology.h
WorkletMapTopology.h
vtkm::rendering::Cylinderizer::Cylinderize::operator()
VTKM_EXEC void operator()(const vtkm::Id &pointOffset, vtkm::CellShapeTagWedge vtkmNotUsed(shapeType), const VecType &cellIndices, const vtkm::Id &cellId, OutputPortal &outputIndices) const
Definition: Cylinderizer.h:286
DataSet.h
vtkm::worklet::WorkletVisitCellsWithPoints::FieldInCell
FieldInVisit FieldInCell
Definition: WorkletMapTopology.h:261
vtkm::exec::arg::WorkIndex
The ExecutionSignature tag to use to get the work index.
Definition: WorkIndex.h:39
vtkm::CELL_SHAPE_QUAD
@ CELL_SHAPE_QUAD
Definition: CellShape.h:45