Fix policy use in FilterDataSet::MapFieldOntoOutput

In FilterDataSet::MapFieldOntoOutput, it was getting each field to map
using the traits reserved for the active field. However, when mapping a
field outside of the DoExecute, we want to consider a broader set of
types.
This commit is contained in:
Kenneth Moreland 2019-09-19 10:59:19 -05:00
parent 72739144f1
commit 40ad325699

@ -57,8 +57,7 @@ inline VTKM_CONT bool FilterDataSet<Derived>::MapFieldOntoOutput(
using FunctorType = internal::ResolveFieldTypeAndMap<Derived, DerivedPolicy>;
FunctorType functor(static_cast<Derived*>(this), result, metaData, policy, valid);
using Traits = vtkm::filter::FilterTraits<Derived>;
vtkm::cont::CastAndCall(vtkm::filter::ApplyPolicyFieldActive(field, policy, Traits()), functor);
vtkm::cont::CastAndCall(vtkm::filter::ApplyPolicyFieldNotActive(field, policy), functor);
//the bool valid will be modified by the map algorithm to hold if the
//mapping occurred or not. If the mapping was good a new field has been