VTK-m  2.0
Public Types | Public Member Functions | Private Types | Private Attributes | List of all members
vtkm::worklet::ScatterPermutation< PermutationStorage > Class Template Reference

A scatter that maps input to output based on a permutation array. More...

#include <ScatterPermutation.h>

Inheritance diagram for vtkm::worklet::ScatterPermutation< PermutationStorage >:

Public Types

using OutputToInputMapType = PermutationArrayHandle
 
using VisitArrayType = vtkm::cont::ArrayHandleConstant< vtkm::IdComponent >
 

Public Member Functions

 ScatterPermutation (const PermutationArrayHandle &permutation)
 
template<typename RangeType >
VTKM_CONT vtkm::Id GetOutputRange (RangeType) const
 
template<typename RangeType >
VTKM_CONT OutputToInputMapType GetOutputToInputMap (RangeType) const
 
VTKM_CONT OutputToInputMapType GetOutputToInputMap () const
 
VTKM_CONT VisitArrayType GetVisitArray (vtkm::Id inputRange) const
 
VTKM_CONT VisitArrayType GetVisitArray (vtkm::Id3 inputRange) const
 

Private Types

using PermutationArrayHandle = vtkm::cont::ArrayHandle< vtkm::Id, PermutationStorage >
 

Private Attributes

PermutationArrayHandle Permutation
 

Detailed Description

template<typename PermutationStorage = VTKM_DEFAULT_STORAGE_TAG>
class vtkm::worklet::ScatterPermutation< PermutationStorage >

A scatter that maps input to output based on a permutation array.

The Scatter classes are responsible for defining how much output is generated based on some sized input. ScatterPermutation is similar to ScatterCounting but can have lesser memory usage for some cases. The constructor takes an array of ids, where each entry maps the corresponding output to an input. The ids can be in any order and there can be duplicates. Note that even with duplicates the VistIndex is always 0.

Member Typedef Documentation

◆ OutputToInputMapType

template<typename PermutationStorage = VTKM_DEFAULT_STORAGE_TAG>
using vtkm::worklet::ScatterPermutation< PermutationStorage >::OutputToInputMapType = PermutationArrayHandle

◆ PermutationArrayHandle

template<typename PermutationStorage = VTKM_DEFAULT_STORAGE_TAG>
using vtkm::worklet::ScatterPermutation< PermutationStorage >::PermutationArrayHandle = vtkm::cont::ArrayHandle<vtkm::Id, PermutationStorage>
private

◆ VisitArrayType

template<typename PermutationStorage = VTKM_DEFAULT_STORAGE_TAG>
using vtkm::worklet::ScatterPermutation< PermutationStorage >::VisitArrayType = vtkm::cont::ArrayHandleConstant<vtkm::IdComponent>

Constructor & Destructor Documentation

◆ ScatterPermutation()

template<typename PermutationStorage = VTKM_DEFAULT_STORAGE_TAG>
vtkm::worklet::ScatterPermutation< PermutationStorage >::ScatterPermutation ( const PermutationArrayHandle permutation)
inline

Member Function Documentation

◆ GetOutputRange()

template<typename PermutationStorage = VTKM_DEFAULT_STORAGE_TAG>
template<typename RangeType >
VTKM_CONT vtkm::Id vtkm::worklet::ScatterPermutation< PermutationStorage >::GetOutputRange ( RangeType  ) const
inline

◆ GetOutputToInputMap() [1/2]

template<typename PermutationStorage = VTKM_DEFAULT_STORAGE_TAG>
VTKM_CONT OutputToInputMapType vtkm::worklet::ScatterPermutation< PermutationStorage >::GetOutputToInputMap ( ) const
inline

◆ GetOutputToInputMap() [2/2]

template<typename PermutationStorage = VTKM_DEFAULT_STORAGE_TAG>
template<typename RangeType >
VTKM_CONT OutputToInputMapType vtkm::worklet::ScatterPermutation< PermutationStorage >::GetOutputToInputMap ( RangeType  ) const
inline

◆ GetVisitArray() [1/2]

template<typename PermutationStorage = VTKM_DEFAULT_STORAGE_TAG>
VTKM_CONT VisitArrayType vtkm::worklet::ScatterPermutation< PermutationStorage >::GetVisitArray ( vtkm::Id  inputRange) const
inline

◆ GetVisitArray() [2/2]

template<typename PermutationStorage = VTKM_DEFAULT_STORAGE_TAG>
VTKM_CONT VisitArrayType vtkm::worklet::ScatterPermutation< PermutationStorage >::GetVisitArray ( vtkm::Id3  inputRange) const
inline

Member Data Documentation

◆ Permutation

template<typename PermutationStorage = VTKM_DEFAULT_STORAGE_TAG>
PermutationArrayHandle vtkm::worklet::ScatterPermutation< PermutationStorage >::Permutation
private

The documentation for this class was generated from the following file: