Merge topic 'cast_and_call_for_cellset_extrude'
adc9e63df vtkm::cont::CastAndCall now supports CellSetExtrude Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !1805
This commit is contained in:
commit
f45e3ae1b8
@ -33,6 +33,7 @@ template <typename T, typename S, typename U, typename V>
|
||||
class CellSetExplicit;
|
||||
template <typename T, typename S>
|
||||
class CellSetPermutation;
|
||||
class CellSetExtrude;
|
||||
|
||||
/// A Generic interface to CastAndCall. The default implementation simply calls
|
||||
/// DynamicObject's CastAndCall, but specializations of this function exist for
|
||||
@ -106,6 +107,15 @@ void CastAndCall(const vtkm::cont::CellSetPermutation<PermutationType, CellSetTy
|
||||
f(cellset, std::forward<Args>(args)...);
|
||||
}
|
||||
|
||||
/// A specialization of CastAndCall for basic CellSetExtrude types,
|
||||
/// Since the type is already known no deduction is needed.
|
||||
/// This specialization is used to simplify numerous worklet algorithms
|
||||
template <typename Functor, typename... Args>
|
||||
void CastAndCall(const vtkm::cont::CellSetExtrude& cellset, Functor&& f, Args&&... args)
|
||||
{
|
||||
f(cellset, std::forward<Args>(args)...);
|
||||
}
|
||||
|
||||
/// CastAndCall if the condition is true.
|
||||
template <typename... Args>
|
||||
void ConditionalCastAndCall(std::true_type, Args&&... args)
|
||||
|
Loading…
Reference in New Issue
Block a user