diff --git a/examples/mesh_quality/MeshQuality.cxx b/examples/mesh_quality/MeshQuality.cxx index 2ee3d578a..b58a78bc1 100644 --- a/examples/mesh_quality/MeshQuality.cxx +++ b/examples/mesh_quality/MeshQuality.cxx @@ -258,7 +258,7 @@ int main(int argc, char* argv[]) // A cell metric is now computed for every shape type that exists in the // input dataset. - vtkm::filter::mesh_info::CellMetric shapeMetric = vtkm::filter::mesh_info::CellMetric::VOLUME; + vtkm::filter::mesh_info::CellMetric shapeMetric = vtkm::filter::mesh_info::CellMetric::Volume; try { diff --git a/vtkm/cont/DynamicCellSet.h b/vtkm/cont/DynamicCellSet.h index b8774db69..01a57307b 100644 --- a/vtkm/cont/DynamicCellSet.h +++ b/vtkm/cont/DynamicCellSet.h @@ -10,21 +10,8 @@ #ifndef vtk_m_cont_DynamicCellSet_h #define vtk_m_cont_DynamicCellSet_h -#include -#include -#include -#include -#include -#include #include -#include - -namespace vtkm -{ -namespace cont -{ - struct VTKM_DEPRECATED(1.8, "Use UnknownCellSet.h or UncertainCellSet.h.") DynamicCellSet_h_header_is_deprecated { @@ -37,218 +24,4 @@ inline void EmitDynamicCellSetHDeprecationWarning() ++x.x; } -// This is a deprecated class. Don't warn about deprecation while implementing -// deprecated functionality. -VTKM_DEPRECATED_SUPPRESS_BEGIN - -/// \brief Holds a cell set without having to specify concrete type. -/// -/// \c DynamicCellSet holds a \c CellSet object using runtime polymorphism to -/// manage different subclass types and template parameters of the subclasses -/// rather than compile-time templates. This adds a programming convenience -/// that helps avoid a proliferation of templates. It also provides the -/// management necessary to interface VTK-m with data sources where types will -/// not be known until runtime. -/// -/// To interface between the runtime polymorphism and the templated algorithms -/// in VTK-m, \c DynamicCellSet contains a method named \c CastAndCall that -/// will determine the correct type from some known list of cell set types. -/// This mechanism is used internally by VTK-m's worklet invocation mechanism -/// to determine the type when running algorithms. -/// -/// By default, \c DynamicCellSet will assume that the value type in the array -/// matches one of the types specified by \c VTKM_DEFAULT_CELL_SET_LIST. -/// This list can be changed by using the \c ResetCellSetList method. It is -/// worthwhile to match these lists closely to the possible types that might be -/// used. If a type is missing you will get a runtime error. If there are more -/// types than necessary, then the template mechanism will create a lot of -/// object code that is never used, and keep in mind that the number of -/// combinations grows exponentially when using multiple \c Dynamic* objects. -/// -/// The actual implementation of \c DynamicCellSet is in a templated class -/// named \c DynamicCellSetBase, which is templated on the list of cell set -/// types. \c DynamicCellSet is really just a typedef of \c DynamicCellSetBase -/// with the default cell set list. -/// -template -class VTKM_ALWAYS_EXPORT VTKM_DEPRECATED(1.8, - "Use vtkm::cont::UncertainCellSet.") DynamicCellSetBase - : public vtkm::cont::UncertainCellSet -{ - using Superclass = vtkm::cont::UncertainCellSet; - -public: - using Superclass::Superclass; - - VTKM_CONT DynamicCellSetBase NewInstance() const - { - return DynamicCellSetBase(this->Superclass::NewInstance()); - } - - template - VTKM_CONT vtkm::cont::DynamicCellSetBase ResetCellSetList(NewCellSetList) const - { - return vtkm::cont::DynamicCellSetBase(*this); - } - template - VTKM_CONT vtkm::cont::DynamicCellSetBase ResetCellSetList() const - { - return vtkm::cont::DynamicCellSetBase(*this); - } -}; - -struct VTKM_ALWAYS_EXPORT VTKM_DEPRECATED(1.8, "Use vtkm::cont::UnknownCellSet.") DynamicCellSet - : public vtkm::cont::UnknownCellSet -{ - using UnknownCellSet::UnknownCellSet; - - DynamicCellSet() = default; - - DynamicCellSet(const vtkm::cont::UnknownCellSet& src) - : UnknownCellSet(src) - { - } - - operator vtkm::cont::DynamicCellSetBase() const - { - return vtkm::cont::DynamicCellSetBase{ *this }; - } - - VTKM_CONT vtkm::cont::DynamicCellSet NewInstance() const - { - return vtkm::cont::DynamicCellSet(this->UnknownCellSet::NewInstance()); - } - - template - VTKM_CONT vtkm::cont::DynamicCellSetBase ResetCellSetList(NewCellSetList) const - { - return vtkm::cont::DynamicCellSetBase(*this); - } - template - VTKM_CONT vtkm::cont::DynamicCellSetBase ResetCellSetList() const - { - return vtkm::cont::DynamicCellSetBase(*this); - } -}; - -namespace internal -{ - -template -struct DynamicTransformTraits> -{ - using DynamicTag = vtkm::cont::internal::DynamicTransformTagCastAndCall; -}; - -template <> -struct DynamicTransformTraits -{ - using DynamicTag = vtkm::cont::internal::DynamicTransformTagCastAndCall; -}; - -} // namespace internal - -namespace internal -{ - -/// Checks to see if the given object is a dynamic cell set. It contains a -/// typedef named \c type that is either std::true_type or std::false_type. -/// Both of these have a typedef named value with the respective boolean value. -/// -template -struct DynamicCellSetCheck -{ - using type = vtkm::cont::internal::UnknownCellSetCheck; -}; - -#define VTKM_IS_DYNAMIC_CELL_SET(T) \ - VTKM_STATIC_ASSERT(::vtkm::cont::internal::DynamicCellSetCheck::type::value) - -#define VTKM_IS_DYNAMIC_OR_STATIC_CELL_SET(T) \ - VTKM_STATIC_ASSERT(::vtkm::cont::internal::CellSetCheck::type::value || \ - ::vtkm::cont::internal::DynamicCellSetCheck::type::value) - -} // namespace internal -} -} // namespace vtkm::cont - -//============================================================================= -// Specializations of serialization related classes -/// @cond SERIALIZATION -namespace mangled_diy_namespace -{ - -namespace internal -{ - -struct DynamicCellSetSerializeFunctor -{ - template - void operator()(const CellSetType& cs, BinaryBuffer& bb) const - { - vtkmdiy::save(bb, vtkm::cont::SerializableTypeString::Get()); - vtkmdiy::save(bb, cs); - } -}; - -template -struct DynamicCellSetDeserializeFunctor -{ - template - void operator()(CellSetType, - vtkm::cont::DynamicCellSetBase& dh, - const std::string& typeString, - bool& success, - BinaryBuffer& bb) const - { - if (!success && (typeString == vtkm::cont::SerializableTypeString::Get())) - { - CellSetType cs; - vtkmdiy::load(bb, cs); - dh = vtkm::cont::DynamicCellSetBase(cs); - success = true; - } - } -}; - -} // internal - -template -struct Serialization> -{ -private: - using Type = vtkm::cont::DynamicCellSetBase; - -public: - static VTKM_CONT void save(BinaryBuffer& bb, const Type& obj) - { - obj.CastAndCall(internal::DynamicCellSetSerializeFunctor{}, bb); - } - - static VTKM_CONT void load(BinaryBuffer& bb, Type& obj) - { - std::string typeString; - vtkmdiy::load(bb, typeString); - - bool success = false; - vtkm::ListForEach(internal::DynamicCellSetDeserializeFunctor{}, - CellSetTypes{}, - obj, - typeString, - success, - bb); - - if (!success) - { - throw vtkm::cont::ErrorBadType("Error deserializing DynamicCellSet. Message TypeString: " + - typeString); - } - } -}; - -} // diy -/// @endcond SERIALIZATION - -VTKM_DEPRECATED_SUPPRESS_END - #endif //vtk_m_cont_DynamicCellSet_h diff --git a/vtkm/cont/UncertainCellSet.h b/vtkm/cont/UncertainCellSet.h index 329e94863..3709e52fc 100644 --- a/vtkm/cont/UncertainCellSet.h +++ b/vtkm/cont/UncertainCellSet.h @@ -201,4 +201,142 @@ public: /// @endcond SERIALIZATION +// Implement the deprecated functionality of DynamicCellSetBase, which was replaced +// by UnknownCellSet/UncertainCellSet. Everything below this line (up to the #endif +// for the include guard) can be deleted once the deprecated functionality is removed. + +namespace vtkm +{ +namespace cont +{ + +// This is a deprecated class. Don't warn about deprecation while implementing +// deprecated functionality. +VTKM_DEPRECATED_SUPPRESS_BEGIN + +template +class VTKM_ALWAYS_EXPORT VTKM_DEPRECATED(1.8, + "Use vtkm::cont::UncertainCellSet.") DynamicCellSetBase + : public vtkm::cont::UncertainCellSet +{ + using Superclass = vtkm::cont::UncertainCellSet; + +public: + using Superclass::Superclass; + + VTKM_CONT DynamicCellSetBase NewInstance() const + { + return DynamicCellSetBase(this->Superclass::NewInstance()); + } + + template + VTKM_CONT vtkm::cont::DynamicCellSetBase ResetCellSetList(NewCellSetList) const + { + return vtkm::cont::DynamicCellSetBase(*this); + } + template + VTKM_CONT vtkm::cont::DynamicCellSetBase ResetCellSetList() const + { + return vtkm::cont::DynamicCellSetBase(*this); + } +}; + +inline DynamicCellSet::operator vtkm::cont::DynamicCellSetBase() const +{ + return vtkm::cont::DynamicCellSetBase{ *this }; +} + +namespace internal +{ + +template +struct DynamicTransformTraits> +{ + using DynamicTag = vtkm::cont::internal::DynamicTransformTagCastAndCall; +}; + +} // namespace internal + +} +} // namespace vtkm::cont + +//============================================================================= +// Specializations of serialization related classes +/// @cond SERIALIZATION +namespace mangled_diy_namespace +{ + +namespace internal +{ + +struct DynamicCellSetSerializeFunctor +{ + template + void operator()(const CellSetType& cs, BinaryBuffer& bb) const + { + vtkmdiy::save(bb, vtkm::cont::SerializableTypeString::Get()); + vtkmdiy::save(bb, cs); + } +}; + +template +struct DynamicCellSetDeserializeFunctor +{ + template + void operator()(CellSetType, + vtkm::cont::DynamicCellSetBase& dh, + const std::string& typeString, + bool& success, + BinaryBuffer& bb) const + { + if (!success && (typeString == vtkm::cont::SerializableTypeString::Get())) + { + CellSetType cs; + vtkmdiy::load(bb, cs); + dh = vtkm::cont::DynamicCellSetBase(cs); + success = true; + } + } +}; + +} // internal + +template +struct Serialization> +{ +private: + using Type = vtkm::cont::DynamicCellSetBase; + +public: + static VTKM_CONT void save(BinaryBuffer& bb, const Type& obj) + { + obj.CastAndCall(internal::DynamicCellSetSerializeFunctor{}, bb); + } + + static VTKM_CONT void load(BinaryBuffer& bb, Type& obj) + { + std::string typeString; + vtkmdiy::load(bb, typeString); + + bool success = false; + vtkm::ListForEach(internal::DynamicCellSetDeserializeFunctor{}, + CellSetTypes{}, + obj, + typeString, + success, + bb); + + if (!success) + { + throw vtkm::cont::ErrorBadType("Error deserializing DynamicCellSet. Message TypeString: " + + typeString); + } + } +}; + +} // diy +/// @endcond SERIALIZATION + +VTKM_DEPRECATED_SUPPRESS_END + #endif //vtk_m_cont_UncertainCellSet_h diff --git a/vtkm/cont/UnknownCellSet.h b/vtkm/cont/UnknownCellSet.h index 8b2c61f38..a566603be 100644 --- a/vtkm/cont/UnknownCellSet.h +++ b/vtkm/cont/UnknownCellSet.h @@ -14,6 +14,8 @@ #include #include +#include + #include #include @@ -392,4 +394,119 @@ public: /// @endcond SERIALIZATION +// Implement the deprecated functionality of DynamicCellSet, which was replaced +// by UnknownCellSet/UncertainCellSet. Everything below this line (up to the #endif +// for the include guard) can be deleted once the deprecated functionality is removed. + +// Headers originally included from DynamicCellSet.h but not UnknownCellSet.h +#include +#include +#include + +namespace vtkm +{ +namespace cont +{ + +// This is a deprecated class. Don't warn about deprecation while implementing +// deprecated functionality. +VTKM_DEPRECATED_SUPPRESS_BEGIN + +// Forward declaration +template +class DynamicCellSetBase; + +/// \brief Holds a cell set without having to specify concrete type. +/// +/// \c DynamicCellSet holds a \c CellSet object using runtime polymorphism to +/// manage different subclass types and template parameters of the subclasses +/// rather than compile-time templates. This adds a programming convenience +/// that helps avoid a proliferation of templates. It also provides the +/// management necessary to interface VTK-m with data sources where types will +/// not be known until runtime. +/// +/// To interface between the runtime polymorphism and the templated algorithms +/// in VTK-m, \c DynamicCellSet contains a method named \c CastAndCall that +/// will determine the correct type from some known list of cell set types. +/// This mechanism is used internally by VTK-m's worklet invocation mechanism +/// to determine the type when running algorithms. +/// +/// By default, \c DynamicCellSet will assume that the value type in the array +/// matches one of the types specified by \c VTKM_DEFAULT_CELL_SET_LIST. +/// This list can be changed by using the \c ResetCellSetList method. It is +/// worthwhile to match these lists closely to the possible types that might be +/// used. If a type is missing you will get a runtime error. If there are more +/// types than necessary, then the template mechanism will create a lot of +/// object code that is never used, and keep in mind that the number of +/// combinations grows exponentially when using multiple \c Dynamic* objects. +/// +/// The actual implementation of \c DynamicCellSet is in a templated class +/// named \c DynamicCellSetBase, which is templated on the list of cell set +/// types. \c DynamicCellSet is really just a typedef of \c DynamicCellSetBase +/// with the default cell set list. +/// +struct VTKM_ALWAYS_EXPORT VTKM_DEPRECATED(1.8, "Use vtkm::cont::UnknownCellSet.") DynamicCellSet + : public vtkm::cont::UnknownCellSet +{ + using UnknownCellSet::UnknownCellSet; + + DynamicCellSet() = default; + + DynamicCellSet(const vtkm::cont::UnknownCellSet& src) + : UnknownCellSet(src) + { + } + + operator vtkm::cont::DynamicCellSetBase() const; + + VTKM_CONT vtkm::cont::DynamicCellSet NewInstance() const + { + return vtkm::cont::DynamicCellSet(this->UnknownCellSet::NewInstance()); + } + + template + VTKM_CONT vtkm::cont::DynamicCellSetBase ResetCellSetList(NewCellSetList) const + { + return vtkm::cont::DynamicCellSetBase(*this); + } + template + VTKM_CONT vtkm::cont::DynamicCellSetBase ResetCellSetList() const + { + return vtkm::cont::DynamicCellSetBase(*this); + } +}; + +namespace internal +{ + +template <> +struct DynamicTransformTraits +{ + using DynamicTag = vtkm::cont::internal::DynamicTransformTagCastAndCall; +}; + +/// Checks to see if the given object is a dynamic cell set. It contains a +/// typedef named \c type that is either std::true_type or std::false_type. +/// Both of these have a typedef named value with the respective boolean value. +/// +template +struct DynamicCellSetCheck +{ + using type = vtkm::cont::internal::UnknownCellSetCheck; +}; + +#define VTKM_IS_DYNAMIC_CELL_SET(T) \ + VTKM_STATIC_ASSERT(::vtkm::cont::internal::DynamicCellSetCheck::type::value) + +#define VTKM_IS_DYNAMIC_OR_STATIC_CELL_SET(T) \ + VTKM_STATIC_ASSERT(::vtkm::cont::internal::CellSetCheck::type::value || \ + ::vtkm::cont::internal::DynamicCellSetCheck::type::value) + +} // namespace internal + +} +} // namespace vtkm::cont + +VTKM_DEPRECATED_SUPPRESS_END + #endif //vtk_m_cont_UnknownCellSet_h diff --git a/vtkm/filter/CMakeLists.txt b/vtkm/filter/CMakeLists.txt index 05412e8bf..94bf205d8 100644 --- a/vtkm/filter/CMakeLists.txt +++ b/vtkm/filter/CMakeLists.txt @@ -46,7 +46,7 @@ set(deprecated_headers PointTransform.h Slice.h SplitSharpEdges.h - SurfaceNormal.h + SurfaceNormals.h Tetrahedralize.h Threshold.h ThresholdPoints.h diff --git a/vtkm/filter/CellAverage.h b/vtkm/filter/CellAverage.h index e5b17fcda..b4250cc53 100644 --- a/vtkm/filter/CellAverage.h +++ b/vtkm/filter/CellAverage.h @@ -28,12 +28,6 @@ inline void CellAverage_deprecated_warning() CellAverage_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_conversion::CellAverage.") CellAverage - : public vtkm::filter::field_conversion::CellAverage -{ - using field_conversion::CellAverage::CellAverage; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/CellMeasures.h b/vtkm/filter/CellMeasures.h index dbb95e00d..17b1fafc5 100644 --- a/vtkm/filter/CellMeasures.h +++ b/vtkm/filter/CellMeasures.h @@ -13,68 +13,6 @@ #include #include -namespace vtkm -{ - -struct VTKM_DEPRECATED(1.8, "IntegrateOver is no longer supported") IntegrateOver -{ -}; -struct VTKM_DEPRECATED(1.8, "IntegrateOverCurve is no longer supported") IntegrateOverCurve - : IntegrateOver -{ - static constexpr IntegrationType value = ArcLength; -}; -struct VTKM_DEPRECATED(1.8, "IntegrateOverSurface is no longer supported") IntegrateOverSurface - : IntegrateOver -{ - static constexpr IntegrationType value = Area; -}; -struct VTKM_DEPRECATED(1.8, "IntegrateOverSurface is no longer supported") IntegrateOverSolid - : IntegrateOver -{ - static constexpr IntegrationType value = Volume; -}; - -// Lists of acceptable types of integration -using ArcLength VTKM_DEPRECATED(1.8, "Use vtkm::filter::mesh_info::IntegrationType::ArcLength") = - vtkm::List; -using Area VTKM_DEPRECATED(1.8, "Use vtkm::filter::mesh_info::IntegrationType::Area") = - vtkm::List; -using Volume VTKM_DEPRECATED(1.8, "Use vtkm::filter::mesh_info::IntegrationType::Volume") = - vtkm::List; -using AllMeasures VTKM_DEPRECATED(1.8, - "Use vtkm::filter::mesh_info::IntegrationType::AllMeasures") = - vtkm::List; - -namespace detail -{ - -IntegrationType OldToNewIntegrationType(vtkm::List<>) -{ - return static_cast(0); -} - -template -IntegrationType OldToNewIntegrationType(vtkm::List) -{ - return T::value | OldToNewIntegrationType(vtkm::List{}); -} - -} // namespace detail - -namespace filter -{ -template -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::mesh_info::CellMeasures.") CellMeasures - : public vtkm::filter::mesh_info::CellMeasures -{ -public: - CellMeasures() - : vtkm::filter::mesh_info::CellMeasures(vtkm::detail::OldToNewIntegrationType(IntegrationTypeList{}) - { - } -}; - VTKM_DEPRECATED(1.8, "Use vtkm/filter/mesh_info/CellMeasures.h instead of vtkm/filter/CellMeasures.h.") inline void CellMeasures_deprecated() {} @@ -83,7 +21,4 @@ inline void CellMeasures_deprecated_warning() { CellMeasures_deprecated(); } - -} // namespace filter -} // namespace vtkm #endif //vtk_m_filter_CellMeasures_h diff --git a/vtkm/filter/CellSetConnectivity.h b/vtkm/filter/CellSetConnectivity.h index 21f3ad13b..7609cc688 100644 --- a/vtkm/filter/CellSetConnectivity.h +++ b/vtkm/filter/CellSetConnectivity.h @@ -28,12 +28,6 @@ inline void CellSetConnectivity_deprecated_warning() CellSetConnectivity_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::connected_components::CellSetConnectivity.") - CellSetConnectivity : public vtkm::filter::connected_components::CellSetConnectivity -{ - using connected_components::CellSetConnectivity::CellSetConnectivity; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/CleanGrid.h b/vtkm/filter/CleanGrid.h index 66e762598..4da9de239 100644 --- a/vtkm/filter/CleanGrid.h +++ b/vtkm/filter/CleanGrid.h @@ -26,12 +26,6 @@ inline void CleanGrid_deprecated_warning() CleanGrid_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::clean_grid::CleanGrid.") CleanGrid - : public vtkm::filter::clean_grid::CleanGrid -{ - using clean_grid::CleanGrid::CleanGrid; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ClipWithField.h b/vtkm/filter/ClipWithField.h index d05608281..a9d56d221 100644 --- a/vtkm/filter/ClipWithField.h +++ b/vtkm/filter/ClipWithField.h @@ -27,12 +27,6 @@ inline void ClipWithField_deprecated_warning() ClipWithField_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::contour::ClipWithField.") ClipWithField - : public vtkm::filter::contour::ClipWithField -{ - using contour::ClipWithField::ClipWithField; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ClipWithImplicitFunction.h b/vtkm/filter/ClipWithImplicitFunction.h index f1c7ff375..86c51b4d2 100644 --- a/vtkm/filter/ClipWithImplicitFunction.h +++ b/vtkm/filter/ClipWithImplicitFunction.h @@ -28,12 +28,6 @@ inline void ClipWithImplicitFunction_deprecated_warning() ClipWithImplicitFunction_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::contour::ClipWithImplicitFunction.") - ClipWithImplicitFunction : public vtkm::filter::contour::ClipWithImplicitFunction -{ - using contour::ClipWithImplicitFunction::ClipWithImplicitFunction; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ComputeMoments.h b/vtkm/filter/ComputeMoments.h index 912e78b67..475ea2575 100644 --- a/vtkm/filter/ComputeMoments.h +++ b/vtkm/filter/ComputeMoments.h @@ -28,12 +28,6 @@ inline void ComputeMoments_deprecated_warning() ComputeMoments_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::image_processing::ComputeMoments.") ComputeMoments - : public vtkm::filter::image_processing::ComputeMoments -{ - using image_processing::ComputeMoments::ComputeMoments; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/Contour.h b/vtkm/filter/Contour.h index 1016d458d..e7ee66394 100644 --- a/vtkm/filter/Contour.h +++ b/vtkm/filter/Contour.h @@ -26,12 +26,6 @@ inline void Contour_deprecated_warning() Contour_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::contour::Contour.") Contour - : public vtkm::filter::contour::Contour -{ - using contour::Contour::Contour; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/CoordinateSystemTransform.h b/vtkm/filter/CoordinateSystemTransform.h index aeb6de21c..61c59c0dc 100644 --- a/vtkm/filter/CoordinateSystemTransform.h +++ b/vtkm/filter/CoordinateSystemTransform.h @@ -11,7 +11,8 @@ #define vtk_m_filter_CoordinateSystemTransform_h #include -#include +#include +#include namespace vtkm { @@ -19,7 +20,8 @@ namespace filter { VTKM_DEPRECATED(1.8, - "Use vtkm/filter/field_transform/CoordinateSystemTransform.h instead of " + "Use vtkm/filter/field_transform/CylindricalCoordinateTransform.h or " + "vtkm/filter/field_transform/SphericalCoordinateTransform.h instead of " "vtkm/filter/CoordinateSystemTransform.h.") inline void CoordinateSystemTransform_deprecated() {} @@ -28,12 +30,6 @@ inline void CoordinateSystemTransform_deprecated_warning() CoordinateSystemTransform_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_transform::CoordinateSystemTransform.") - CoordinateSystemTransform : public vtkm::filter::field_transform::CoordinateSystemTransform -{ - using field_transform::CoordinateSystemTransform::CoordinateSystemTransform; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/CrossProduct.h b/vtkm/filter/CrossProduct.h index f7e4865bf..56f62986d 100644 --- a/vtkm/filter/CrossProduct.h +++ b/vtkm/filter/CrossProduct.h @@ -29,12 +29,6 @@ inline void CrossProduct_deprecated_warning() CrossProduct_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::vector_analysis::CrossProduct.") CrossProduct - : public vtkm::filter::vector_analysis::CrossProduct -{ - using vector_analysis::CrossProduct::CrossProduct; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/DotProduct.h b/vtkm/filter/DotProduct.h index 5fde052e8..97c4e7a4d 100644 --- a/vtkm/filter/DotProduct.h +++ b/vtkm/filter/DotProduct.h @@ -27,11 +27,6 @@ inline void DotProduct_deprecated_warning() DotProduct_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::vector_analysis::DotProduct.") DotProduct - : public vtkm::filter::vector_analysis::DotProduct -{ - using vector_analysis::DotProduct::DotProduct; -}; } } // namespace vtkm::filter diff --git a/vtkm/filter/Entropy.h b/vtkm/filter/Entropy.h index a2e5163d0..309d0d013 100644 --- a/vtkm/filter/Entropy.h +++ b/vtkm/filter/Entropy.h @@ -26,12 +26,6 @@ inline void Entropy_deprecated_warning() Entropy_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::density_estimate::Entropy.") Entropy - : public vtkm::filter::density_estimate::Entropy -{ - using density_estimate::Entropy::Entropy; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ExternalFaces.h b/vtkm/filter/ExternalFaces.h index 66524a1b0..1f42bd5bf 100644 --- a/vtkm/filter/ExternalFaces.h +++ b/vtkm/filter/ExternalFaces.h @@ -28,12 +28,6 @@ inline void ExternalFaces_deprecated_warning() ExternalFaces_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::ExternalFaces.") ExternalFaces - : public vtkm::filter::entity_extraction::ExternalFaces -{ - using entity_extraction::ExternalFaces::ExternalFaces; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ExtractGeometry.h b/vtkm/filter/ExtractGeometry.h index 869863c83..e9d3e7594 100644 --- a/vtkm/filter/ExtractGeometry.h +++ b/vtkm/filter/ExtractGeometry.h @@ -28,12 +28,6 @@ inline void ExtractGeometry_deprecated_warning() ExtractGeometry_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::ExtractGeometry.") ExtractGeometry - : public vtkm::filter::entity_extraction::ExtractGeometry -{ - using entity_extraction::ExtractGeometry::ExtractGeometry; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ExtractPoints.h b/vtkm/filter/ExtractPoints.h index b24caf50f..ee0f210c1 100644 --- a/vtkm/filter/ExtractPoints.h +++ b/vtkm/filter/ExtractPoints.h @@ -28,12 +28,6 @@ inline void ExtractPoints_deprecated_warning() ExtractPoints_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::ExtractPoints.") ExtractPoints - : public vtkm::filter::entity_extraction::ExtractPoints -{ - using entity_extraction::ExtractPoints::ExtractPoints; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ExtractStructured.h b/vtkm/filter/ExtractStructured.h index a92bddd6b..fe9e77d3d 100644 --- a/vtkm/filter/ExtractStructured.h +++ b/vtkm/filter/ExtractStructured.h @@ -28,13 +28,6 @@ inline void ExtractStructured_deprecated_warning() ExtractStructured_deprecated(); } -class VTKM_DEPRECATED(1.8, - "Use vtkm::filter::entity_extraction::ExtractStructured.") ExtractStructured - : public vtkm::filter::entity_extraction::ExtractStructured -{ - using entity_extraction::ExtractStructured::ExtractStructured; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/FieldToColors.h b/vtkm/filter/FieldToColors.h index 7d8f7fd31..a26b77773 100644 --- a/vtkm/filter/FieldToColors.h +++ b/vtkm/filter/FieldToColors.h @@ -28,12 +28,6 @@ inline void FieldToColors_deprecated_warning() FieldToColors_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_transform::FieldToColors.") FieldToColors - : public vtkm::filter::field_transform::FieldToColors -{ - using field_transform::FieldToColors::FieldToColors; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/GenerateIds.h b/vtkm/filter/GenerateIds.h index 7af613132..01f529968 100644 --- a/vtkm/filter/GenerateIds.h +++ b/vtkm/filter/GenerateIds.h @@ -28,12 +28,6 @@ inline void GenerateIds_deprecated_warning() GenerateIds_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_transform::GenerateIds.") GenerateIds - : public vtkm::filter::field_transform::GenerateIds -{ - using field_transform::GenerateIds::GenerateIds; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/GhostCellClassify.h b/vtkm/filter/GhostCellClassify.h index 4dcd5ea48..c7b6a2336 100644 --- a/vtkm/filter/GhostCellClassify.h +++ b/vtkm/filter/GhostCellClassify.h @@ -28,12 +28,6 @@ inline void GhostCellClassify_deprecated_warning() GhostCellClassify_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::mesh_info::GhostCellClassify.") GhostCellClassify - : public vtkm::filter::mesh_info::GhostCellClassify -{ - using mesh_info::GhostCellClassify::GhostCellClassify; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/GhostCellRemove.h b/vtkm/filter/GhostCellRemove.h index 59fd8f5fe..4da23781a 100644 --- a/vtkm/filter/GhostCellRemove.h +++ b/vtkm/filter/GhostCellRemove.h @@ -28,12 +28,6 @@ inline void GhostCellRemove_deprecated_warning() GhostCellRemove_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::GhostCellRemove.") GhostCellRemove - : public vtkm::filter::entity_extraction::GhostCellRemove -{ - using entity_extraction::GhostCellRemove::GhostCellRemove; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/Gradient.h b/vtkm/filter/Gradient.h index 465870f41..7faf4b53b 100644 --- a/vtkm/filter/Gradient.h +++ b/vtkm/filter/Gradient.h @@ -27,12 +27,6 @@ inline void Gradient_deprecated_warning() Gradient_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::vector_analysis::Gradient.") Gradient - : public vtkm::filter::vector_analysis::Gradient -{ - using vector_analysis::Gradient::Gradient; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/Histogram.h b/vtkm/filter/Histogram.h index 6ad4e2bb0..9f75ad9f6 100644 --- a/vtkm/filter/Histogram.h +++ b/vtkm/filter/Histogram.h @@ -27,12 +27,6 @@ inline void Histogram_deprecated_warning() Histogram_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::density_estimate::Histogram.") Histogram - : public vtkm::filter::density_estimate::Histogram -{ - using density_estimate::Histogram::Histogram; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ImageConnectivity.h b/vtkm/filter/ImageConnectivity.h index 704f82dd5..2f56c087c 100644 --- a/vtkm/filter/ImageConnectivity.h +++ b/vtkm/filter/ImageConnectivity.h @@ -28,12 +28,6 @@ inline void ImageConnectivity_deprecated_warning() ImageConnectivity_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::connected_components::ImageConnectivity.") - ImageConnectivity : public vtkm::filter::connected_components::ImageConnectivity -{ - using connected_components::ImageConnectivity::ImageConnectivity; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ImageDifference.h b/vtkm/filter/ImageDifference.h index 1e9cc24d7..15dd2dd9a 100644 --- a/vtkm/filter/ImageDifference.h +++ b/vtkm/filter/ImageDifference.h @@ -28,12 +28,6 @@ inline void ImageDifference_deprecated_warning() ImageDifference_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::image_processing::ImageDifference.") ImageDifference - : public vtkm::filter::image_processing::ImageDifference -{ - using image_processing::ImageDifference::ImageDifference; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ImageMedian.h b/vtkm/filter/ImageMedian.h index 7d1b241c8..377c68d96 100644 --- a/vtkm/filter/ImageMedian.h +++ b/vtkm/filter/ImageMedian.h @@ -28,12 +28,6 @@ inline void ImageMedian_deprecated_warning() ImageMedian_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::image_processing::ImageMedian.") ImageMedian - : public vtkm::filter::image_processing::ImageMedian -{ - using image_processing::ImageMedian::ImageMedian; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/MIRFilter.hxx b/vtkm/filter/MIRFilter.hxx index 0e2040540..9a62186d3 100644 --- a/vtkm/filter/MIRFilter.hxx +++ b/vtkm/filter/MIRFilter.hxx @@ -100,8 +100,8 @@ inline VTKM_CONT vtkm::cont::DataSet MIRFilter::DoExecute( input.GetCoordinateSystem(this->GetActiveCoordinateSystemIndex()); vtkm::cont::ArrayHandle avgSizeTot; vtkm::worklet::MeshQuality getVol; - getVol.SetMetric(c3 > 0 ? vtkm::filter::mesh_info::CellMetric::VOLUME - : vtkm::filter::mesh_info::CellMetric::AREA); + getVol.SetMetric(c3 > 0 ? vtkm::filter::mesh_info::CellMetric::Volume + : vtkm::filter::mesh_info::CellMetric::Area); this->Invoke(getVol, vtkm::filter::ApplyPolicyCellSet(input.GetCellSet(), policy, *this), inputCoords.GetData(), diff --git a/vtkm/filter/Mask.h b/vtkm/filter/Mask.h index 4eabdb99f..a58c82a98 100644 --- a/vtkm/filter/Mask.h +++ b/vtkm/filter/Mask.h @@ -26,12 +26,6 @@ inline void Mask_deprecated_warning() Mask_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::Mask.") Mask - : public vtkm::filter::entity_extraction::Mask -{ - using entity_extraction::Mask::Mask; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/MaskPoints.h b/vtkm/filter/MaskPoints.h index 1eba5a658..6547a3d2b 100644 --- a/vtkm/filter/MaskPoints.h +++ b/vtkm/filter/MaskPoints.h @@ -28,12 +28,6 @@ inline void MaskPoints_deprecated_warning() MaskPoints_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::MaskPoints.") MaskPoints - : public vtkm::filter::entity_extraction::MaskPoints -{ - using entity_extraction::MaskPoints::MaskPoints; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/MeshQuality.h b/vtkm/filter/MeshQuality.h index 9dd9f236f..61ab2ffb1 100644 --- a/vtkm/filter/MeshQuality.h +++ b/vtkm/filter/MeshQuality.h @@ -27,12 +27,6 @@ inline void MeshQuality_deprecated_warning() MeshQuality_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::mesh_info::MeshQuality.") MeshQuality - : public vtkm::filter::mesh_info::MeshQuality -{ - using mesh_info::MeshQuality::MeshQuality; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/NDEntropy.h b/vtkm/filter/NDEntropy.h index ad0eac2e2..c54b51350 100644 --- a/vtkm/filter/NDEntropy.h +++ b/vtkm/filter/NDEntropy.h @@ -27,12 +27,6 @@ inline void NDEntropy_deprecated_warning() NDEntropy_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::density_estimate::NDEntropy.") NDEntropy - : public vtkm::filter::density_estimate::NDEntropy -{ - using density_estimate::NDEntropy::NDEntropy; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/NDHistogram.h b/vtkm/filter/NDHistogram.h index 68a0b59a2..8f0e37abf 100644 --- a/vtkm/filter/NDHistogram.h +++ b/vtkm/filter/NDHistogram.h @@ -28,12 +28,6 @@ inline void NDHistogram_deprecated_warning() NDHistogram_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::density_estimate::NDHistogram.") NDHistogram - : public vtkm::filter::density_estimate::NDHistogram -{ - using density_estimate::NDHistogram::NDHistogram; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ParticleDensityCloudInCell.h b/vtkm/filter/ParticleDensityCloudInCell.h index 35a93e15a..01aa90829 100644 --- a/vtkm/filter/ParticleDensityCloudInCell.h +++ b/vtkm/filter/ParticleDensityCloudInCell.h @@ -28,12 +28,6 @@ inline void ParticleDensityCloudInCell_deprecated_warning() ParticleDensityCloudInCell_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::density_estimate::ParticleDensityCloudInCell.") - ParticleDensityCloudInCell : public vtkm::filter::density_estimate::ParticleDensityCloudInCell -{ - using density_estimate::ParticleDensityCloudInCell::ParticleDensityCloudInCell; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ParticleDensityNearestGridPoint.h b/vtkm/filter/ParticleDensityNearestGridPoint.h index 4edbd5dba..cec7c7e44 100644 --- a/vtkm/filter/ParticleDensityNearestGridPoint.h +++ b/vtkm/filter/ParticleDensityNearestGridPoint.h @@ -28,13 +28,6 @@ inline void ParticleDensityNearestGridPoint_deprecated_warning() ParticleDensityNearestGridPoint_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::density_estimate::ParticleDensityNearestGridPoint.") - ParticleDensityNearestGridPoint - : public vtkm::filter::density_estimate::ParticleDensityNearestGridPoint -{ - using density_estimate::ParticleDensityNearestGridPoint::ParticleDensityNearestGridPoint; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/PointAverage.h b/vtkm/filter/PointAverage.h index 9e1b2dfc6..874782c0c 100644 --- a/vtkm/filter/PointAverage.h +++ b/vtkm/filter/PointAverage.h @@ -28,12 +28,6 @@ inline void PointAverage_deprecated_warning() PointAverage_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_conversion::PointAverage.") PointAverage - : public vtkm::filter::field_conversion::PointAverage -{ - using field_conversion::PointAverage::PointAverage; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/PointElevation.h b/vtkm/filter/PointElevation.h index e0573d60f..b11b1a928 100644 --- a/vtkm/filter/PointElevation.h +++ b/vtkm/filter/PointElevation.h @@ -28,12 +28,6 @@ inline void PointElevation_deprecated_warning() PointElevation_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_transform::PointElevation.") PointElevation - : public vtkm::filter::field_transform::PointElevation -{ - using field_transform::PointElevation::PointElevation; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/PointTransform.h b/vtkm/filter/PointTransform.h index e7c48eb4d..5cb5c5a69 100644 --- a/vtkm/filter/PointTransform.h +++ b/vtkm/filter/PointTransform.h @@ -28,12 +28,6 @@ inline void PointTransform_deprecated_warning() PointTransform_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_transform::PointTransform.") PointTransform - : public vtkm::filter::field_transform::PointTransform -{ - using field_transform::PointTransform::PointTransform; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/Slice.h b/vtkm/filter/Slice.h index c618c9405..d263d2a76 100644 --- a/vtkm/filter/Slice.h +++ b/vtkm/filter/Slice.h @@ -26,12 +26,6 @@ inline void Slice_deprecated_warning() Slice_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::contour::Slice.") Slice - : public vtkm::filter::contour::Slice -{ - using contour::Slice::Slice; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/SplitSharpEdges.h b/vtkm/filter/SplitSharpEdges.h index 29ac9013c..24d59bd14 100644 --- a/vtkm/filter/SplitSharpEdges.h +++ b/vtkm/filter/SplitSharpEdges.h @@ -28,13 +28,6 @@ inline void SplitSharpEdges_deprecated_warning() SplitSharpEdges_deprecated(); } -class VTKM_DEPRECATED(1.8, - "Use vtkm::filter::geometry_refinement::SplitSharpEdges.") SplitSharpEdges - : public vtkm::filter::geometry_refinement::SplitSharpEdges -{ - using geometry_refinement::SplitSharpEdges::SplitSharpEdges; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/SurfaceNormal.h b/vtkm/filter/SurfaceNormal.h deleted file mode 100644 index a800ff1cb..000000000 --- a/vtkm/filter/SurfaceNormal.h +++ /dev/null @@ -1,40 +0,0 @@ -//============================================================================ -// Copyright (c) Kitware, Inc. -// All rights reserved. -// See LICENSE.txt for details. -// -// This software is distributed WITHOUT ANY WARRANTY; without even -// the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -// PURPOSE. See the above copyright notice for more information. -//============================================================================ -#ifndef vtk_m_filter_SurfaceNormal_h -#define vtk_m_filter_SurfaceNormal_h - -#include -#include - -namespace vtkm -{ -namespace filter -{ - -VTKM_DEPRECATED( - 1.8, - "Use vtkm/filter/vector_analysis/SurfaceNormal.h instead of vtkm/filter/SurfaceNormal.h.") -inline void SurfaceNormal_deprecated() {} - -inline void SurfaceNormal_deprecated_warning() -{ - SurfaceNormal_deprecated(); -} - -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::vector_analysis::SurfaceNormal.") SurfaceNormal - : public vtkm::filter::vector_analysis::SurfaceNormal -{ - using vector_analysis::SurfaceNormal::SurfaceNormal; -}; - -} -} // namespace vtkm::filter - -#endif //vtk_m_filter_SurfaceNormal_h diff --git a/vtkm/filter/SurfaceNormals.h b/vtkm/filter/SurfaceNormals.h new file mode 100644 index 000000000..b72508ea4 --- /dev/null +++ b/vtkm/filter/SurfaceNormals.h @@ -0,0 +1,34 @@ +//============================================================================ +// Copyright (c) Kitware, Inc. +// All rights reserved. +// See LICENSE.txt for details. +// +// This software is distributed WITHOUT ANY WARRANTY; without even +// the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +// PURPOSE. See the above copyright notice for more information. +//============================================================================ +#ifndef vtk_m_filter_SurfaceNormals_h +#define vtk_m_filter_SurfaceNormals_h + +#include +#include + +namespace vtkm +{ +namespace filter +{ + +VTKM_DEPRECATED( + 1.8, + "Use vtkm/filter/vector_analysis/SurfaceNormals.h instead of vtkm/filter/SurfaceNormals.h.") +inline void SurfaceNormals_deprecated() {} + +inline void SurfaceNormals_deprecated_warning() +{ + SurfaceNormals_deprecated(); +} + +} +} // namespace vtkm::filter + +#endif //vtk_m_filter_SurfaceNormals_h diff --git a/vtkm/filter/Tetrahedralize.h b/vtkm/filter/Tetrahedralize.h index 193310805..cc01be273 100644 --- a/vtkm/filter/Tetrahedralize.h +++ b/vtkm/filter/Tetrahedralize.h @@ -28,12 +28,6 @@ inline void Tetrahedralize_deprecated_warning() Tetrahedralize_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::geometry_refinement::Tetrahedralize.") Tetrahedralize - : public vtkm::filter::geometry_refinement::Tetrahedralize -{ - using geometry_refinement::Tetrahedralize::Tetrahedralize; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/Threshold.h b/vtkm/filter/Threshold.h index 2c544733f..a14385451 100644 --- a/vtkm/filter/Threshold.h +++ b/vtkm/filter/Threshold.h @@ -27,12 +27,6 @@ inline void Threshold_deprecated_warning() Threshold_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::Threshold.") Threshold - : public vtkm::filter::entity_extraction::Threshold -{ - using entity_extraction::Threshold::Threshold; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ThresholdPoints.h b/vtkm/filter/ThresholdPoints.h index 277f97c2b..73839e19f 100644 --- a/vtkm/filter/ThresholdPoints.h +++ b/vtkm/filter/ThresholdPoints.h @@ -28,12 +28,6 @@ inline void ThresholdPoints_deprecated_warning() ThresholdPoints_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::ThresholdPoints.") ThresholdPoints - : public vtkm::filter::entity_extraction::ThresholdPoints -{ - using entity_extraction::ThresholdPoints::ThresholdPoints; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/Triangulate.h b/vtkm/filter/Triangulate.h index 1ef7ef322..c79d94ff8 100644 --- a/vtkm/filter/Triangulate.h +++ b/vtkm/filter/Triangulate.h @@ -28,12 +28,6 @@ inline void Triangulate_deprecated_warning() Triangulate_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::geometry_refinement::Triangulate.") Triangulate - : public vtkm::filter::geometry_refinement::Triangulate -{ - using geometry_refinement::Triangulate::Triangulate; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/Tube.h b/vtkm/filter/Tube.h index df5a9403b..588ba57f7 100644 --- a/vtkm/filter/Tube.h +++ b/vtkm/filter/Tube.h @@ -26,12 +26,6 @@ inline void Tube_deprecated_warning() Tube_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::geometry_refinement::Tube.") Tube - : public vtkm::filter::geometry_refinement::Tube -{ - using geometry_refinement::Tube::Tube; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/VectorMagnitude.h b/vtkm/filter/VectorMagnitude.h index 34a9c1144..e28311dd3 100644 --- a/vtkm/filter/VectorMagnitude.h +++ b/vtkm/filter/VectorMagnitude.h @@ -28,12 +28,6 @@ inline void VectorMagnitude_deprecated_warning() VectorMagnitude_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::vector_analysis::VectorMagnitude.") VectorMagnitude - : public vtkm::filter::vector_analysis::VectorMagnitude -{ - using vector_analysis::VectorMagnitude::VectorMagnitude; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/VertexClustering.h b/vtkm/filter/VertexClustering.h index 09a2127f8..e672fba63 100644 --- a/vtkm/filter/VertexClustering.h +++ b/vtkm/filter/VertexClustering.h @@ -28,12 +28,6 @@ inline void VertexClustering_deprecated_warning() VertexClustering_deprecated(); } -class VTKM_DEPRECATED(1.8, - "Use vtkm::filter::geometry_refinement::VertexClustering.") VertexClustering - : public vtkm::filter::geometry_refinement::VertexClustering -{ - using geometry_refinement::VertexClustering::VertexClustering; -}; } } // namespace vtkm::filter diff --git a/vtkm/filter/WarpScalar.h b/vtkm/filter/WarpScalar.h index 9e3939c9a..4d4d27cf5 100644 --- a/vtkm/filter/WarpScalar.h +++ b/vtkm/filter/WarpScalar.h @@ -27,12 +27,6 @@ inline void WarpScalar_deprecated_warning() WarpScalar_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_transform::WarpScalar.") WarpScalar - : public vtkm::filter::field_transform::WarpScalar -{ - using field_transform::WarpScalar::WarpScalar; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/WarpVector.h b/vtkm/filter/WarpVector.h index f893a3c30..5a24d3aa1 100644 --- a/vtkm/filter/WarpVector.h +++ b/vtkm/filter/WarpVector.h @@ -27,12 +27,6 @@ inline void WarpVector_deprecated_warning() WarpVector_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_transform::WarpVector.") WarpVector - : public vtkm::filter::field_transform::WarpVector -{ - using field_transform::WarpVector::WarpVector; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ZFPCompressor1D.h b/vtkm/filter/ZFPCompressor1D.h index c28c65ba9..453bdfd56 100644 --- a/vtkm/filter/ZFPCompressor1D.h +++ b/vtkm/filter/ZFPCompressor1D.h @@ -27,12 +27,6 @@ inline void ZFPCompressor1D_deprecated_warning() ZFPCompressor1D_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::zfp::ZFPCompressor1D.") ZFPCompressor1D - : public vtkm::filter::zfp::ZFPCompressor1D -{ - using zfp::ZFPCompressor1D::ZFPCompressor1D; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ZFPCompressor2D.h b/vtkm/filter/ZFPCompressor2D.h index a71d4778e..ce07f14eb 100644 --- a/vtkm/filter/ZFPCompressor2D.h +++ b/vtkm/filter/ZFPCompressor2D.h @@ -27,12 +27,6 @@ inline void ZFPCompressor2D_deprecated_warning() ZFPCompressor2D_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::zfp::ZFPCompressor2D.") ZFPCompressor2D - : public vtkm::filter::zfp::ZFPCompressor2D -{ - using zfp::ZFPCompressor2D::ZFPCompressor2D; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ZFPCompressor3D.h b/vtkm/filter/ZFPCompressor3D.h index a310aba3a..8ba525048 100644 --- a/vtkm/filter/ZFPCompressor3D.h +++ b/vtkm/filter/ZFPCompressor3D.h @@ -27,12 +27,6 @@ inline void ZFPCompressor3D_deprecated_warning() ZFPCompressor3D_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::zfp::ZFPCompressor3D.") ZFPCompressor3D - : public vtkm::filter::zfp::ZFPCompressor3D -{ - using zfp::ZFPCompressor3D::ZFPCompressor3D; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ZFPDecompressor1D.h b/vtkm/filter/ZFPDecompressor1D.h index cb5056f18..49636d9ec 100644 --- a/vtkm/filter/ZFPDecompressor1D.h +++ b/vtkm/filter/ZFPDecompressor1D.h @@ -28,12 +28,6 @@ inline void ZFPDecompressor1D_deprecated_warning() ZFPDecompressor1D_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::zfp::ZFPDecompressor1D.") ZFPDecompressor1D - : public vtkm::filter::zfp::ZFPDecompressor1D -{ - using zfp::ZFPDecompressor1D::ZFPDecompressor1D; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ZFPDecompressor2D.h b/vtkm/filter/ZFPDecompressor2D.h index 8f514bb5f..30d798ec8 100644 --- a/vtkm/filter/ZFPDecompressor2D.h +++ b/vtkm/filter/ZFPDecompressor2D.h @@ -28,12 +28,6 @@ inline void ZFPDecompressor2D_deprecated_warning() ZFPDecompressor2D_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::zfp::ZFPDecompressor2D.") ZFPDecompressor2D - : public vtkm::filter::zfp::ZFPDecompressor2D -{ - using zfp::ZFPDecompressor2D::ZFPDecompressor2D; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/ZFPDecompressor3D.h b/vtkm/filter/ZFPDecompressor3D.h index 532d2252f..a46350959 100644 --- a/vtkm/filter/ZFPDecompressor3D.h +++ b/vtkm/filter/ZFPDecompressor3D.h @@ -28,12 +28,6 @@ inline void ZFPDecompressor3D_deprecated_warning() ZFPDecompressor3D_deprecated(); } -class VTKM_DEPRECATED(1.8, "Use vtkm::filter::zfp::ZFPDecompressor3D.") ZFPDecompressor3D - : public vtkm::filter::zfp::ZFPDecompressor3D -{ - using zfp::ZFPDecompressor3D::ZFPDecompressor3D; -}; - } } // namespace vtkm::filter diff --git a/vtkm/filter/clean_grid/CleanGrid.h b/vtkm/filter/clean_grid/CleanGrid.h index 9eb4e3174..2e8fec952 100644 --- a/vtkm/filter/clean_grid/CleanGrid.h +++ b/vtkm/filter/clean_grid/CleanGrid.h @@ -96,6 +96,13 @@ private: bool FastMerge = true; }; } // namespace clean_grid + +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::clean_grid::CleanGrid.") CleanGrid + : public vtkm::filter::clean_grid::CleanGrid +{ + using clean_grid::CleanGrid::CleanGrid; +}; + } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/connected_components/CellSetConnectivity.h b/vtkm/filter/connected_components/CellSetConnectivity.h index f026e5d69..efb95ee58 100644 --- a/vtkm/filter/connected_components/CellSetConnectivity.h +++ b/vtkm/filter/connected_components/CellSetConnectivity.h @@ -20,6 +20,7 @@ namespace filter { namespace connected_components { + /// \brief Finds groups of cells that are connected together through their topology. /// /// Finds and labels groups of cells that are connected together through their topology. @@ -37,8 +38,16 @@ private: VTKM_CONT vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; }; -} -} -} + +} // namespace connected_components + +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::connected_components::CellSetConnectivity.") + CellSetConnectivity : public vtkm::filter::connected_components::CellSetConnectivity +{ + using connected_components::CellSetConnectivity::CellSetConnectivity; +}; + +} // namespace filter +} // namespace vtkm #endif //vtk_m_filter_connected_components_CellSetConnectivity_h diff --git a/vtkm/filter/connected_components/ImageConnectivity.h b/vtkm/filter/connected_components/ImageConnectivity.h index e66bc6b3e..6ab5f216b 100644 --- a/vtkm/filter/connected_components/ImageConnectivity.h +++ b/vtkm/filter/connected_components/ImageConnectivity.h @@ -41,6 +41,13 @@ private: vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; }; } // namespace connected_components + +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::connected_components::ImageConnectivity.") + ImageConnectivity : public vtkm::filter::connected_components::ImageConnectivity +{ + using connected_components::ImageConnectivity::ImageConnectivity; +}; + } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/contour/ClipWithField.h b/vtkm/filter/contour/ClipWithField.h index b0bc3375c..7087a9aa3 100644 --- a/vtkm/filter/contour/ClipWithField.h +++ b/vtkm/filter/contour/ClipWithField.h @@ -45,6 +45,11 @@ private: bool Invert = false; }; } // namespace contour +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::contour::ClipWithField.") ClipWithField + : public vtkm::filter::contour::ClipWithField +{ + using contour::ClipWithField::ClipWithField; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/contour/ClipWithImplicitFunction.h b/vtkm/filter/contour/ClipWithImplicitFunction.h index cdb0119a8..a7af459ec 100644 --- a/vtkm/filter/contour/ClipWithImplicitFunction.h +++ b/vtkm/filter/contour/ClipWithImplicitFunction.h @@ -42,6 +42,11 @@ private: bool Invert = false; }; } // namespace contour +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::contour::ClipWithImplicitFunction.") + ClipWithImplicitFunction : public vtkm::filter::contour::ClipWithImplicitFunction +{ + using contour::ClipWithImplicitFunction::ClipWithImplicitFunction; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/contour/Contour.h b/vtkm/filter/contour/Contour.h index 062502abb..257cdbff9 100644 --- a/vtkm/filter/contour/Contour.h +++ b/vtkm/filter/contour/Contour.h @@ -128,6 +128,11 @@ protected: vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& result) override; }; } // namespace contour +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::contour::Contour.") Contour + : public vtkm::filter::contour::Contour +{ + using contour::Contour::Contour; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/contour/Slice.h b/vtkm/filter/contour/Slice.h index c2bb4c18d..10244bc1b 100644 --- a/vtkm/filter/contour/Slice.h +++ b/vtkm/filter/contour/Slice.h @@ -37,6 +37,11 @@ private: vtkm::ImplicitFunctionGeneral Function; }; } // namespace contour +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::contour::Slice.") Slice + : public vtkm::filter::contour::Slice +{ + using contour::Slice::Slice; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/density_estimate/Entropy.h b/vtkm/filter/density_estimate/Entropy.h index e820ab50a..60e709caf 100644 --- a/vtkm/filter/density_estimate/Entropy.h +++ b/vtkm/filter/density_estimate/Entropy.h @@ -45,6 +45,11 @@ private: vtkm::Id NumberOfBins = 10; }; } // namespace density_estimate +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::density_estimate::Entropy.") Entropy + : public vtkm::filter::density_estimate::Entropy +{ + using density_estimate::Entropy::Entropy; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/density_estimate/Histogram.h b/vtkm/filter/density_estimate/Histogram.h index 1600a80a6..6e23ac471 100644 --- a/vtkm/filter/density_estimate/Histogram.h +++ b/vtkm/filter/density_estimate/Histogram.h @@ -78,6 +78,11 @@ private: vtkm::Range Range; }; } // namespace density_estimate +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::density_estimate::Histogram.") Histogram + : public vtkm::filter::density_estimate::Histogram +{ + using density_estimate::Histogram::Histogram; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/density_estimate/NDEntropy.h b/vtkm/filter/density_estimate/NDEntropy.h index 6cfcd5f13..8639de57f 100644 --- a/vtkm/filter/density_estimate/NDEntropy.h +++ b/vtkm/filter/density_estimate/NDEntropy.h @@ -35,8 +35,13 @@ private: std::vector NumOfBins; std::vector FieldNames; }; -} -} -} // namespace vtkm::filter +} // namespace density_estimate +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::density_estimate::NDEntropy.") NDEntropy + : public vtkm::filter::density_estimate::NDEntropy +{ + using density_estimate::NDEntropy::NDEntropy; +}; +} // namespace filter +} // namespace vtkm #endif //vtk_m_filter_density_estimate_NDEntropy_h diff --git a/vtkm/filter/density_estimate/NDHistogram.h b/vtkm/filter/density_estimate/NDHistogram.h index 2a4cbeff5..86d60be27 100644 --- a/vtkm/filter/density_estimate/NDHistogram.h +++ b/vtkm/filter/density_estimate/NDHistogram.h @@ -56,6 +56,11 @@ private: std::vector DataRanges; //Min Max of the field }; } // namespace density_estimate +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::density_estimate::NDHistogram.") NDHistogram + : public vtkm::filter::density_estimate::NDHistogram +{ + using density_estimate::NDHistogram::NDHistogram; +}; } // namespace filter } // namespace vtm diff --git a/vtkm/filter/density_estimate/ParticleDensityCloudInCell.h b/vtkm/filter/density_estimate/ParticleDensityCloudInCell.h index 9d3f99932..ed0065a2e 100644 --- a/vtkm/filter/density_estimate/ParticleDensityCloudInCell.h +++ b/vtkm/filter/density_estimate/ParticleDensityCloudInCell.h @@ -50,6 +50,11 @@ private: VTKM_CONT vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; }; } // namespace density_estimate +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::density_estimate::ParticleDensityCloudInCell.") + ParticleDensityCloudInCell : public vtkm::filter::density_estimate::ParticleDensityCloudInCell +{ + using density_estimate::ParticleDensityCloudInCell::ParticleDensityCloudInCell; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/density_estimate/ParticleDensityNearestGridPoint.h b/vtkm/filter/density_estimate/ParticleDensityNearestGridPoint.h index f95947f2e..80740d79b 100644 --- a/vtkm/filter/density_estimate/ParticleDensityNearestGridPoint.h +++ b/vtkm/filter/density_estimate/ParticleDensityNearestGridPoint.h @@ -50,6 +50,12 @@ private: VTKM_CONT vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; }; } // namespace density_estimate +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::density_estimate::ParticleDensityNearestGridPoint.") + ParticleDensityNearestGridPoint + : public vtkm::filter::density_estimate::ParticleDensityNearestGridPoint +{ + using density_estimate::ParticleDensityNearestGridPoint::ParticleDensityNearestGridPoint; +}; } // namespace filter } // namespace vtkm #endif //vtk_m_filter_density_estimate_ParticleDensityNGP_h diff --git a/vtkm/filter/entity_extraction/ExternalFaces.h b/vtkm/filter/entity_extraction/ExternalFaces.h index f15dd276c..79f6d03b4 100644 --- a/vtkm/filter/entity_extraction/ExternalFaces.h +++ b/vtkm/filter/entity_extraction/ExternalFaces.h @@ -76,6 +76,11 @@ private: std::unique_ptr Worklet; }; } // namespace entity_extraction +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::ExternalFaces.") ExternalFaces + : public vtkm::filter::entity_extraction::ExternalFaces +{ + using entity_extraction::ExternalFaces::ExternalFaces; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/entity_extraction/ExtractGeometry.h b/vtkm/filter/entity_extraction/ExtractGeometry.h index c328749db..0afbd0d11 100644 --- a/vtkm/filter/entity_extraction/ExtractGeometry.h +++ b/vtkm/filter/entity_extraction/ExtractGeometry.h @@ -80,8 +80,13 @@ private: bool ExtractOnlyBoundaryCells = false; vtkm::ImplicitFunctionGeneral Function; }; -} -} -} // namespace vtkm::filter +} // namespace entity_extraction +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::ExtractGeometry.") ExtractGeometry + : public vtkm::filter::entity_extraction::ExtractGeometry +{ + using entity_extraction::ExtractGeometry::ExtractGeometry; +}; +} // namespace filter +} // namespace vtkm #endif // vtk_m_fulter_entity_extraction_ExtractGeometry_h diff --git a/vtkm/filter/entity_extraction/ExtractPoints.h b/vtkm/filter/entity_extraction/ExtractPoints.h index 98942c1d0..9b2a454c1 100644 --- a/vtkm/filter/entity_extraction/ExtractPoints.h +++ b/vtkm/filter/entity_extraction/ExtractPoints.h @@ -69,6 +69,11 @@ private: bool CompactPoints = false; }; } // namespace entity_extraction +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::ExtractPoints.") ExtractPoints + : public vtkm::filter::entity_extraction::ExtractPoints +{ + using entity_extraction::ExtractPoints::ExtractPoints; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/entity_extraction/ExtractStructured.h b/vtkm/filter/entity_extraction/ExtractStructured.h index 5218a0a00..d00d8d558 100644 --- a/vtkm/filter/entity_extraction/ExtractStructured.h +++ b/vtkm/filter/entity_extraction/ExtractStructured.h @@ -92,6 +92,12 @@ private: }; } // namespace entity_extraction +class VTKM_DEPRECATED(1.8, + "Use vtkm::filter::entity_extraction::ExtractStructured.") ExtractStructured + : public vtkm::filter::entity_extraction::ExtractStructured +{ + using entity_extraction::ExtractStructured::ExtractStructured; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/entity_extraction/GhostCellRemove.h b/vtkm/filter/entity_extraction/GhostCellRemove.h index 41c17328f..11fbdb718 100644 --- a/vtkm/filter/entity_extraction/GhostCellRemove.h +++ b/vtkm/filter/entity_extraction/GhostCellRemove.h @@ -59,6 +59,11 @@ private: }; } // namespace entity_extraction +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::GhostCellRemove.") GhostCellRemove + : public vtkm::filter::entity_extraction::GhostCellRemove +{ + using entity_extraction::GhostCellRemove::GhostCellRemove; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/entity_extraction/Mask.h b/vtkm/filter/entity_extraction/Mask.h index 4611b0341..4e7117d10 100644 --- a/vtkm/filter/entity_extraction/Mask.h +++ b/vtkm/filter/entity_extraction/Mask.h @@ -8,8 +8,8 @@ // PURPOSE. See the above copyright notice for more information. //============================================================================ -#ifndef vtk_m_filter_Mask_h -#define vtk_m_filter_Mask_h +#ifndef vtk_m_filter_entity_extraction_Mask_h +#define vtk_m_filter_entity_extraction_Mask_h #include #include @@ -47,7 +47,12 @@ private: bool CompactPoints = false; }; } // namespace entity_extraction +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::Mask.") Mask + : public vtkm::filter::entity_extraction::Mask +{ + using entity_extraction::Mask::Mask; +}; } // namespace filter } // namespace vtk -#endif // vtk_m_filter_Mask_h +#endif // vtk_m_filter_entity_extraction_Mask_h diff --git a/vtkm/filter/entity_extraction/MaskPoints.h b/vtkm/filter/entity_extraction/MaskPoints.h index fd78043a6..682e16346 100644 --- a/vtkm/filter/entity_extraction/MaskPoints.h +++ b/vtkm/filter/entity_extraction/MaskPoints.h @@ -46,6 +46,11 @@ private: bool CompactPoints = true; }; } // namespace eneity_extraction +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::MaskPoints.") MaskPoints + : public vtkm::filter::entity_extraction::MaskPoints +{ + using entity_extraction::MaskPoints::MaskPoints; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/entity_extraction/Threshold.h b/vtkm/filter/entity_extraction/Threshold.h index e73392259..8752c6f12 100644 --- a/vtkm/filter/entity_extraction/Threshold.h +++ b/vtkm/filter/entity_extraction/Threshold.h @@ -60,6 +60,11 @@ private: bool ReturnAllInRange = false; }; } // namespace entity_extraction +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::Threshold.") Threshold + : public vtkm::filter::entity_extraction::Threshold +{ + using entity_extraction::Threshold::Threshold; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/entity_extraction/ThresholdPoints.h b/vtkm/filter/entity_extraction/ThresholdPoints.h index 58ce00b47..0fd7f8777 100644 --- a/vtkm/filter/entity_extraction/ThresholdPoints.h +++ b/vtkm/filter/entity_extraction/ThresholdPoints.h @@ -62,6 +62,11 @@ private: bool CompactPoints = false; }; } // namespace entity_extraction +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::entity_extraction::ThresholdPoints.") ThresholdPoints + : public vtkm::filter::entity_extraction::ThresholdPoints +{ + using entity_extraction::ThresholdPoints::ThresholdPoints; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/field_conversion/CellAverage.h b/vtkm/filter/field_conversion/CellAverage.h index f800ee388..33b1cf02b 100644 --- a/vtkm/filter/field_conversion/CellAverage.h +++ b/vtkm/filter/field_conversion/CellAverage.h @@ -33,6 +33,11 @@ private: VTKM_CONT vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; }; } // namespace field_conversion +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_conversion::CellAverage.") CellAverage + : public vtkm::filter::field_conversion::CellAverage +{ + using field_conversion::CellAverage::CellAverage; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/field_conversion/PointAverage.h b/vtkm/filter/field_conversion/PointAverage.h index 4925d90a8..d66bc41cc 100644 --- a/vtkm/filter/field_conversion/PointAverage.h +++ b/vtkm/filter/field_conversion/PointAverage.h @@ -32,6 +32,11 @@ private: VTKM_CONT vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; }; } // namespace field_conversion +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_conversion::PointAverage.") PointAverage + : public vtkm::filter::field_conversion::PointAverage +{ + using field_conversion::PointAverage::PointAverage; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/field_transform/CMakeLists.txt b/vtkm/filter/field_transform/CMakeLists.txt index ac28fd16c..5f150bae1 100644 --- a/vtkm/filter/field_transform/CMakeLists.txt +++ b/vtkm/filter/field_transform/CMakeLists.txt @@ -8,21 +8,23 @@ ## PURPOSE. See the above copyright notice for more information. ##============================================================================ set(field_transform_headers - CoordinateSystemTransform.h + CylindricalCoordinateTransform.h FieldToColors.h GenerateIds.h PointElevation.h PointTransform.h + SphericalCoordinateTransform.h WarpScalar.h WarpVector.h ) set(field_transform_sources - CoordinateSystemTransform.cxx + CylindricalCoordinateTransform.cxx FieldToColors.cxx GenerateIds.cxx PointElevation.cxx PointTransform.cxx + SphericalCoordinateTransform.cxx WarpScalar.cxx WarpVector.cxx ) diff --git a/vtkm/filter/field_transform/CoordinateSystemTransform.cxx b/vtkm/filter/field_transform/CylindricalCoordinateTransform.cxx similarity index 57% rename from vtkm/filter/field_transform/CoordinateSystemTransform.cxx rename to vtkm/filter/field_transform/CylindricalCoordinateTransform.cxx index 41a2fdb6c..3d73cad9d 100644 --- a/vtkm/filter/field_transform/CoordinateSystemTransform.cxx +++ b/vtkm/filter/field_transform/CylindricalCoordinateTransform.cxx @@ -8,7 +8,7 @@ // PURPOSE. See the above copyright notice for more information. //============================================================================ -#include +#include #include namespace vtkm @@ -17,7 +17,7 @@ namespace filter { namespace field_transform { -//----------------------------------------------------------------------------- + vtkm::cont::DataSet CylindricalCoordinateTransform::DoExecute(const vtkm::cont::DataSet& inDataSet) { vtkm::cont::UnknownArrayHandle outArray; @@ -42,30 +42,6 @@ vtkm::cont::DataSet CylindricalCoordinateTransform::DoExecute(const vtkm::cont:: return outDataSet; } -//----------------------------------------------------------------------------- -vtkm::cont::DataSet SphericalCoordinateTransform::DoExecute(const vtkm::cont::DataSet& inDataSet) -{ - vtkm::cont::UnknownArrayHandle outArray; - - auto resolveType = [&](const auto& concrete) { - // use std::decay to remove const ref from the decltype of concrete. - using T = typename std::decay_t::ValueType; - vtkm::cont::ArrayHandle result; - vtkm::worklet::SphericalCoordinateTransform worklet{ this->CartesianToSpherical }; - worklet.Run(concrete, result); - outArray = result; - }; - this->CastAndCallVecField<3>(this->GetFieldFromDataSet(inDataSet), resolveType); - - vtkm::cont::DataSet outDataSet = - this->CreateResult(inDataSet, - inDataSet.GetCellSet(), - vtkm::cont::CoordinateSystem("coordinates", outArray), - [](vtkm::cont::DataSet& out, const vtkm::cont::Field& fieldToPass) { - out.AddField(fieldToPass); - }); - return outDataSet; -} } // namespace field_transform } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/field_transform/CoordinateSystemTransform.h b/vtkm/filter/field_transform/CylindricalCoordinateTransform.h similarity index 67% rename from vtkm/filter/field_transform/CoordinateSystemTransform.h rename to vtkm/filter/field_transform/CylindricalCoordinateTransform.h index 2defa50f7..260300b4a 100644 --- a/vtkm/filter/field_transform/CoordinateSystemTransform.h +++ b/vtkm/filter/field_transform/CylindricalCoordinateTransform.h @@ -8,8 +8,8 @@ // PURPOSE. See the above copyright notice for more information. //============================================================================ -#ifndef vtk_m_filter_field_transform_CoordinateSystemTransform_h -#define vtk_m_filter_field_transform_CoordinateSystemTransform_h +#ifndef vtk_m_filter_field_transform_CylindricalCoordinateTransform_h +#define vtk_m_filter_field_transform_CylindricalCoordinateTransform_h #include #include @@ -35,21 +35,14 @@ private: bool CartesianToCylindrical = true; }; - -class VTKM_FILTER_FIELD_TRANSFORM_EXPORT SphericalCoordinateTransform - : public vtkm::filter::NewFilterField -{ -public: - VTKM_CONT void SetCartesianToSpherical() { CartesianToSpherical = true; } - VTKM_CONT void SetSphericalToCartesian() { CartesianToSpherical = false; } - -private: - VTKM_CONT vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; - - bool CartesianToSpherical = true; -}; } // namespace field_transform +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_transform::CylindricalCoordinateTransform.") + CylindricalCoordinateTransform + : public vtkm::filter::field_transform::CylindricalCoordinateTransform +{ + using field_transform::CylindricalCoordinateTransform::CylindricalCoordinateTransform; +}; } // namespace filter } // namespace vtkm -#endif // vtk_m_filter_field_transform_CoordinateSystemTransform_h +#endif //vtk_m_filter_field_transform_CylindricalCoordinateTransform_h diff --git a/vtkm/filter/field_transform/FieldToColors.h b/vtkm/filter/field_transform/FieldToColors.h index e68cc4a68..4ce66051c 100644 --- a/vtkm/filter/field_transform/FieldToColors.h +++ b/vtkm/filter/field_transform/FieldToColors.h @@ -85,6 +85,11 @@ private: vtkm::Id ModifiedCount = -1; }; } // namespace field_transform +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_transform::FieldToColors.") FieldToColors + : public vtkm::filter::field_transform::FieldToColors +{ + using field_transform::FieldToColors::FieldToColors; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/field_transform/GenerateIds.h b/vtkm/filter/field_transform/GenerateIds.h index 1183c46a0..c49a71e99 100644 --- a/vtkm/filter/field_transform/GenerateIds.h +++ b/vtkm/filter/field_transform/GenerateIds.h @@ -89,6 +89,11 @@ private: vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; }; } // namespace field_transform +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_transform::GenerateIds.") GenerateIds + : public vtkm::filter::field_transform::GenerateIds +{ + using field_transform::GenerateIds::GenerateIds; +}; } // namespace vtkm::filter } // namespace vtkm diff --git a/vtkm/filter/field_transform/PointElevation.h b/vtkm/filter/field_transform/PointElevation.h index ab65af573..378e5838c 100644 --- a/vtkm/filter/field_transform/PointElevation.h +++ b/vtkm/filter/field_transform/PointElevation.h @@ -60,6 +60,11 @@ private: vtkm::Float64 RangeLow = 0.0, RangeHigh = 1.0; }; } // namespace field_transform +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_transform::PointElevation.") PointElevation + : public vtkm::filter::field_transform::PointElevation +{ + using field_transform::PointElevation::PointElevation; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/field_transform/PointTransform.h b/vtkm/filter/field_transform/PointTransform.h index dd37b5ff8..1e339e635 100644 --- a/vtkm/filter/field_transform/PointTransform.h +++ b/vtkm/filter/field_transform/PointTransform.h @@ -103,8 +103,13 @@ private: vtkm::Matrix matrix; bool ChangeCoordinateSystem = true; }; -} -} -} // namespace vtkm::filter +} // namespace field_transform +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_transform::PointTransform.") PointTransform + : public vtkm::filter::field_transform::PointTransform +{ + using field_transform::PointTransform::PointTransform; +}; +} // namespace filter +} // namespace vtkm #endif // vtk_m_filter_field_transform_PointTransform_h diff --git a/vtkm/filter/field_transform/SphericalCoordinateTransform.cxx b/vtkm/filter/field_transform/SphericalCoordinateTransform.cxx new file mode 100644 index 000000000..f22ec860f --- /dev/null +++ b/vtkm/filter/field_transform/SphericalCoordinateTransform.cxx @@ -0,0 +1,45 @@ +//============================================================================ +// Copyright (c) Kitware, Inc. +// All rights reserved. +// See LICENSE.txt for details. +// +// This software is distributed WITHOUT ANY WARRANTY; without even +// the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +// PURPOSE. See the above copyright notice for more information. +//============================================================================ + +#include +#include + +namespace vtkm +{ +namespace filter +{ +namespace field_transform +{ +vtkm::cont::DataSet SphericalCoordinateTransform::DoExecute(const vtkm::cont::DataSet& inDataSet) +{ + vtkm::cont::UnknownArrayHandle outArray; + + auto resolveType = [&](const auto& concrete) { + // use std::decay to remove const ref from the decltype of concrete. + using T = typename std::decay_t::ValueType; + vtkm::cont::ArrayHandle result; + vtkm::worklet::SphericalCoordinateTransform worklet{ this->CartesianToSpherical }; + worklet.Run(concrete, result); + outArray = result; + }; + this->CastAndCallVecField<3>(this->GetFieldFromDataSet(inDataSet), resolveType); + + vtkm::cont::DataSet outDataSet = + this->CreateResult(inDataSet, + inDataSet.GetCellSet(), + vtkm::cont::CoordinateSystem("coordinates", outArray), + [](vtkm::cont::DataSet& out, const vtkm::cont::Field& fieldToPass) { + out.AddField(fieldToPass); + }); + return outDataSet; +} +} // namespace field_transform +} // namespace filter +} // namespace vtkm diff --git a/vtkm/filter/field_transform/SphericalCoordinateTransform.h b/vtkm/filter/field_transform/SphericalCoordinateTransform.h new file mode 100644 index 000000000..b599ef86d --- /dev/null +++ b/vtkm/filter/field_transform/SphericalCoordinateTransform.h @@ -0,0 +1,45 @@ +//============================================================================ +// Copyright (c) Kitware, Inc. +// All rights reserved. +// See LICENSE.txt for details. +// +// This software is distributed WITHOUT ANY WARRANTY; without even +// the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +// PURPOSE. See the above copyright notice for more information. +//============================================================================ + +#ifndef vtk_m_filter_field_transform_SphericalCoordinateTransform_h +#define vtk_m_filter_field_transform_SphericalCoordinateTransform_h + +#include +#include + +namespace vtkm +{ +namespace filter +{ +namespace field_transform +{ + +class VTKM_FILTER_FIELD_TRANSFORM_EXPORT SphericalCoordinateTransform + : public vtkm::filter::NewFilterField +{ +public: + VTKM_CONT void SetCartesianToSpherical() { CartesianToSpherical = true; } + VTKM_CONT void SetSphericalToCartesian() { CartesianToSpherical = false; } + +private: + VTKM_CONT vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; + + bool CartesianToSpherical = true; +}; +} // namespace field_transform +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_transform::SphericalCoordinateTransform.") + SphericalCoordinateTransform : public vtkm::filter::field_transform::SphericalCoordinateTransform +{ + using field_transform::SphericalCoordinateTransform::SphericalCoordinateTransform; +}; +} // namespace filter +} // namespace vtkm + +#endif // vtk_m_filter_field_transform_SphericalCoordinateTransform_h diff --git a/vtkm/filter/field_transform/WarpScalar.h b/vtkm/filter/field_transform/WarpScalar.h index dae002f66..c5554c388 100644 --- a/vtkm/filter/field_transform/WarpScalar.h +++ b/vtkm/filter/field_transform/WarpScalar.h @@ -87,6 +87,11 @@ private: vtkm::FloatDefault ScaleAmount; }; } // namespace field_transform +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_transform::WarpScalar.") WarpScalar + : public vtkm::filter::field_transform::WarpScalar +{ + using field_transform::WarpScalar::WarpScalar; +}; } // namespace filter } // namespace vtkm #endif // vtk_m_filter_field_transform_WarpScalar_h diff --git a/vtkm/filter/field_transform/WarpVector.h b/vtkm/filter/field_transform/WarpVector.h index 6650f4008..8fe44d28e 100644 --- a/vtkm/filter/field_transform/WarpVector.h +++ b/vtkm/filter/field_transform/WarpVector.h @@ -62,6 +62,11 @@ private: vtkm::FloatDefault Scale; }; } // namespace field_transform +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::field_transform::WarpVector.") WarpVector + : public vtkm::filter::field_transform::WarpVector +{ + using field_transform::WarpVector::WarpVector; +}; } // namespace filter } // namespace vtkm #endif // vtk_m_filter_field_transform_WarpVector_h diff --git a/vtkm/filter/field_transform/testing/UnitTestCoordinateSystemTransform.cxx b/vtkm/filter/field_transform/testing/UnitTestCoordinateSystemTransform.cxx index 5270aa94c..081a869bd 100644 --- a/vtkm/filter/field_transform/testing/UnitTestCoordinateSystemTransform.cxx +++ b/vtkm/filter/field_transform/testing/UnitTestCoordinateSystemTransform.cxx @@ -9,7 +9,8 @@ //============================================================================ #include -#include +#include +#include #include diff --git a/vtkm/filter/geometry_refinement/SplitSharpEdges.h b/vtkm/filter/geometry_refinement/SplitSharpEdges.h index 1483904dd..81ef19578 100644 --- a/vtkm/filter/geometry_refinement/SplitSharpEdges.h +++ b/vtkm/filter/geometry_refinement/SplitSharpEdges.h @@ -48,6 +48,12 @@ private: vtkm::FloatDefault FeatureAngle = 30.0; }; } // namespace geometry_refinement +class VTKM_DEPRECATED(1.8, + "Use vtkm::filter::geometry_refinement::SplitSharpEdges.") SplitSharpEdges + : public vtkm::filter::geometry_refinement::SplitSharpEdges +{ + using geometry_refinement::SplitSharpEdges::SplitSharpEdges; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/geometry_refinement/Tetrahedralize.h b/vtkm/filter/geometry_refinement/Tetrahedralize.h index 339bda942..963422962 100644 --- a/vtkm/filter/geometry_refinement/Tetrahedralize.h +++ b/vtkm/filter/geometry_refinement/Tetrahedralize.h @@ -25,6 +25,11 @@ class VTKM_FILTER_GEOMETRY_REFINEMENT_EXPORT Tetrahedralize : public vtkm::filte VTKM_CONT vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; }; } // namespace geometry_refinement +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::geometry_refinement::Tetrahedralize.") Tetrahedralize + : public vtkm::filter::geometry_refinement::Tetrahedralize +{ + using geometry_refinement::Tetrahedralize::Tetrahedralize; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/geometry_refinement/Triangulate.h b/vtkm/filter/geometry_refinement/Triangulate.h index 83030c108..c57245397 100644 --- a/vtkm/filter/geometry_refinement/Triangulate.h +++ b/vtkm/filter/geometry_refinement/Triangulate.h @@ -25,6 +25,11 @@ class VTKM_FILTER_GEOMETRY_REFINEMENT_EXPORT Triangulate : public vtkm::filter:: VTKM_CONT vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; }; } // namespace geometry_refinement +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::geometry_refinement::Triangulate.") Triangulate + : public vtkm::filter::geometry_refinement::Triangulate +{ + using geometry_refinement::Triangulate::Triangulate; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/geometry_refinement/Tube.h b/vtkm/filter/geometry_refinement/Tube.h index 5e37e679c..786c9f7c3 100644 --- a/vtkm/filter/geometry_refinement/Tube.h +++ b/vtkm/filter/geometry_refinement/Tube.h @@ -45,6 +45,11 @@ private: bool Capping{}; }; } // namespace geometry_refinement +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::geometry_refinement::Tube.") Tube + : public vtkm::filter::geometry_refinement::Tube +{ + using geometry_refinement::Tube::Tube; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/geometry_refinement/VertexClustering.h b/vtkm/filter/geometry_refinement/VertexClustering.h index 4b69d43dd..9371e2f5e 100644 --- a/vtkm/filter/geometry_refinement/VertexClustering.h +++ b/vtkm/filter/geometry_refinement/VertexClustering.h @@ -63,6 +63,12 @@ private: vtkm::Id3 NumberOfDivisions = { 256, 256, 256 }; }; } // namespace geometry_refinement +class VTKM_DEPRECATED(1.8, + "Use vtkm::filter::geometry_refinement::VertexClustering.") VertexClustering + : public vtkm::filter::geometry_refinement::VertexClustering +{ + using geometry_refinement::VertexClustering::VertexClustering; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/image_processing/ComputeMoments.h b/vtkm/filter/image_processing/ComputeMoments.h index 466191785..67f97c369 100644 --- a/vtkm/filter/image_processing/ComputeMoments.h +++ b/vtkm/filter/image_processing/ComputeMoments.h @@ -38,6 +38,11 @@ private: vtkm::Int32 Order = 0; }; } // namespace image_processing +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::image_processing::ComputeMoments.") ComputeMoments + : public vtkm::filter::image_processing::ComputeMoments +{ + using image_processing::ComputeMoments::ComputeMoments; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/image_processing/ImageDifference.h b/vtkm/filter/image_processing/ImageDifference.h index a1a2e6456..9a7002ad8 100644 --- a/vtkm/filter/image_processing/ImageDifference.h +++ b/vtkm/filter/image_processing/ImageDifference.h @@ -108,6 +108,11 @@ private: std::string ThresholdFieldName = "threshold-output"; }; } // namespace image_processing +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::image_processing::ImageDifference.") ImageDifference + : public vtkm::filter::image_processing::ImageDifference +{ + using image_processing::ImageDifference::ImageDifference; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/image_processing/ImageMedian.h b/vtkm/filter/image_processing/ImageMedian.h index 4cda91e7e..3fc007717 100644 --- a/vtkm/filter/image_processing/ImageMedian.h +++ b/vtkm/filter/image_processing/ImageMedian.h @@ -44,6 +44,11 @@ private: int Neighborhood = 1; }; } // namespace image_processing +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::image_processing::ImageMedian.") ImageMedian + : public vtkm::filter::image_processing::ImageMedian +{ + using image_processing::ImageMedian::ImageMedian; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/mesh_info/CellMeasures.h b/vtkm/filter/mesh_info/CellMeasures.h index 9c60ba0a4..ad89e0db2 100644 --- a/vtkm/filter/mesh_info/CellMeasures.h +++ b/vtkm/filter/mesh_info/CellMeasures.h @@ -8,8 +8,8 @@ // PURPOSE. See the above copyright notice for more information. //============================================================================ -#ifndef vtk_m_filter_mesh_info_CellMeasure_h -#define vtk_m_filter_mesh_info_CellMeasure_h +#ifndef vtk_m_filter_mesh_info_CellMeasures_h +#define vtk_m_filter_mesh_info_CellMeasures_h #include #include @@ -20,14 +20,26 @@ namespace filter { namespace mesh_info { -enum IntegrationType + +/// \brief Specifies over what types of mesh elements CellMeasures will operate. +enum struct IntegrationType { + None = 0x00, ArcLength = 0x01, Area = 0x02, Volume = 0x04, AllMeasures = ArcLength | Area | Volume }; +VTKM_EXEC_CONT inline IntegrationType operator&(IntegrationType left, IntegrationType right) +{ + return static_cast(static_cast(left) & static_cast(right)); +} +VTKM_EXEC_CONT inline IntegrationType operator|(IntegrationType left, IntegrationType right) +{ + return static_cast(static_cast(left) | static_cast(right)); +} + /// \brief Compute the measure of each (3D) cell in a dataset. /// /// CellMeasures is a filter that generates a new cell data array (i.e., one value @@ -54,4 +66,83 @@ private: } // namespace filter } // namespace vtkm -#endif // vtk_m_filter_mesh_info_CellMeasure_h +// Implement the deprecated functionality of vtkm::filter::CellMeasures, which was moved into the +// mesh_info namespace (along with some other API changes). Everything below this line (up to the +// #endif for the include guard) can be deleted once the deprecated functionality is removed. + +// Don't warn about deprecation while implementing deprecated functionality. +VTKM_DEPRECATED_SUPPRESS_BEGIN + +namespace vtkm +{ + +struct VTKM_DEPRECATED(1.8, "IntegrateOver is no longer supported") IntegrateOver +{ +}; +struct VTKM_DEPRECATED(1.8, "IntegrateOverCurve is no longer supported") IntegrateOverCurve + : IntegrateOver +{ + static constexpr vtkm::filter::mesh_info::IntegrationType value = + vtkm::filter::mesh_info::IntegrationType::ArcLength; +}; +struct VTKM_DEPRECATED(1.8, "IntegrateOverSurface is no longer supported") IntegrateOverSurface + : IntegrateOver +{ + static constexpr vtkm::filter::mesh_info::IntegrationType value = + vtkm::filter::mesh_info::IntegrationType::Area; +}; +struct VTKM_DEPRECATED(1.8, "IntegrateOverSurface is no longer supported") IntegrateOverSolid + : IntegrateOver +{ + static constexpr vtkm::filter::mesh_info::IntegrationType value = + vtkm::filter::mesh_info::IntegrationType::Volume; +}; + +// Lists of acceptable types of integration +using ArcLength VTKM_DEPRECATED(1.8, "Use vtkm::filter::mesh_info::IntegrationType::ArcLength") = + vtkm::List; +using Area VTKM_DEPRECATED(1.8, "Use vtkm::filter::mesh_info::IntegrationType::Area") = + vtkm::List; +using Volume VTKM_DEPRECATED(1.8, "Use vtkm::filter::mesh_info::IntegrationType::Volume") = + vtkm::List; +using AllMeasures VTKM_DEPRECATED(1.8, + "Use vtkm::filter::mesh_info::IntegrationType::AllMeasures") = + vtkm::List; + +namespace detail +{ + +inline vtkm::filter::mesh_info::IntegrationType OldToNewIntegrationType(vtkm::List<>) +{ + return vtkm::filter::mesh_info::IntegrationType::None; +} + +template +inline vtkm::filter::mesh_info::IntegrationType OldToNewIntegrationType(vtkm::List) +{ + return T::value | OldToNewIntegrationType(vtkm::List{}); +} + +} // namespace detail + +namespace filter +{ + +template +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::mesh_info::CellMeasures.") CellMeasures + : public vtkm::filter::mesh_info::CellMeasures +{ +public: + CellMeasures() + : vtkm::filter::mesh_info::CellMeasures( + vtkm::detail::OldToNewIntegrationType(IntegrationTypeList{})) + { + } +}; + +} // namespace filter +} // namespace vtkm + +VTKM_DEPRECATED_SUPPRESS_END + +#endif // vtk_m_filter_mesh_info_CellMeasures_h diff --git a/vtkm/filter/mesh_info/GhostCellClassify.h b/vtkm/filter/mesh_info/GhostCellClassify.h index cbba99230..c55dffb84 100644 --- a/vtkm/filter/mesh_info/GhostCellClassify.h +++ b/vtkm/filter/mesh_info/GhostCellClassify.h @@ -24,6 +24,11 @@ class VTKM_FILTER_MESH_INFO_EXPORT GhostCellClassify : public vtkm::filter::NewF VTKM_CONT vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& inData) override; }; } // namespace mesh_info +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::mesh_info::GhostCellClassify.") GhostCellClassify + : public vtkm::filter::mesh_info::GhostCellClassify +{ + using mesh_info::GhostCellClassify::GhostCellClassify; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/mesh_info/MeshQuality.cxx b/vtkm/filter/mesh_info/MeshQuality.cxx index 7de67109b..2906fae3c 100644 --- a/vtkm/filter/mesh_info/MeshQuality.cxx +++ b/vtkm/filter/mesh_info/MeshQuality.cxx @@ -33,28 +33,28 @@ namespace //Names of the available cell metrics, for use in //the output dataset fields const std::map MetricNames = { - { CellMetric::AREA, "area" }, - { CellMetric::ASPECT_GAMMA, "aspectGamma" }, - { CellMetric::ASPECT_RATIO, "aspectRatio" }, - { CellMetric::CONDITION, "condition" }, - { CellMetric::DIAGONAL_RATIO, "diagonalRatio" }, - { CellMetric::DIMENSION, "dimension" }, - { CellMetric::JACOBIAN, "jacobian" }, - { CellMetric::MAX_ANGLE, "maxAngle" }, - { CellMetric::MAX_DIAGONAL, "maxDiagonal" }, - { CellMetric::MIN_ANGLE, "minAngle" }, - { CellMetric::MIN_DIAGONAL, "minDiagonal" }, - { CellMetric::ODDY, "oddy" }, - { CellMetric::RELATIVE_SIZE_SQUARED, "relativeSizeSquared" }, - { CellMetric::SCALED_JACOBIAN, "scaledJacobian" }, - { CellMetric::SHAPE, "shape" }, - { CellMetric::SHAPE_AND_SIZE, "shapeAndSize" }, - { CellMetric::SHEAR, "shear" }, - { CellMetric::SKEW, "skew" }, - { CellMetric::STRETCH, "stretch" }, - { CellMetric::TAPER, "taper" }, - { CellMetric::VOLUME, "volume" }, - { CellMetric::WARPAGE, "warpage" } + { CellMetric::Area, "area" }, + { CellMetric::AspectGama, "aspectGamma" }, + { CellMetric::AspectRatio, "aspectRatio" }, + { CellMetric::Condition, "condition" }, + { CellMetric::DiagonalRatio, "diagonalRatio" }, + { CellMetric::Dimension, "dimension" }, + { CellMetric::Jacobian, "jacobian" }, + { CellMetric::MaxAngle, "maxAngle" }, + { CellMetric::MaxDiagonal, "maxDiagonal" }, + { CellMetric::MinAngle, "minAngle" }, + { CellMetric::MinDiagonal, "minDiagonal" }, + { CellMetric::Oddy, "oddy" }, + { CellMetric::RelativeSizeSquared, "relativeSizeSquared" }, + { CellMetric::ScaledJacobian, "scaledJacobian" }, + { CellMetric::Shape, "shape" }, + { CellMetric::ShapeAndSize, "shapeAndSize" }, + { CellMetric::Shear, "shear" }, + { CellMetric::Skew, "skew" }, + { CellMetric::Stretch, "stretch" }, + { CellMetric::Taper, "taper" }, + { CellMetric::Volume, "volume" }, + { CellMetric::Warpage, "warpage" } }; } // anonymous namespace @@ -77,8 +77,8 @@ VTKM_CONT vtkm::cont::DataSet MeshQuality::DoExecute(const vtkm::cont::DataSet& vtkm::cont::UnknownCellSet inputCellSet = input.GetCellSet(); vtkm::worklet::MeshQuality qualityWorklet; - if (this->MyMetric == CellMetric::RELATIVE_SIZE_SQUARED || - this->MyMetric == CellMetric::SHAPE_AND_SIZE) + if (this->MyMetric == CellMetric::RelativeSizeSquared || + this->MyMetric == CellMetric::ShapeAndSize) { vtkm::worklet::MeshQuality subWorklet; vtkm::FloatDefault totalArea; @@ -89,11 +89,11 @@ VTKM_CONT vtkm::cont::DataSet MeshQuality::DoExecute(const vtkm::cont::DataSet& using T = typename std::decay_t::ValueType::ComponentType; vtkm::cont::ArrayHandle array; - subWorklet.SetMetric(CellMetric::AREA); + subWorklet.SetMetric(CellMetric::Area); this->Invoke(subWorklet, inputCellSet, concrete, array); totalArea = (vtkm::FloatDefault)vtkm::cont::Algorithm::Reduce(array, T{}); - subWorklet.SetMetric(CellMetric::VOLUME); + subWorklet.SetMetric(CellMetric::Volume); this->Invoke(subWorklet, inputCellSet, concrete, array); totalVolume = (vtkm::FloatDefault)vtkm::cont::Algorithm::Reduce(array, T{}); }; @@ -128,3 +128,69 @@ VTKM_CONT vtkm::cont::DataSet MeshQuality::DoExecute(const vtkm::cont::DataSet& } // namespace mesh_info } // namespace filter } // namespace vtkm + +namespace vtkm +{ +namespace filter +{ + +VTKM_DEPRECATED_SUPPRESS_BEGIN + +vtkm::filter::mesh_info::CellMetric MeshQuality::ConvertCellMetric( + vtkm::filter::CellMetric oldMetricEnum) +{ + switch (oldMetricEnum) + { + case vtkm::filter::CellMetric::AREA: + return vtkm::filter::mesh_info::CellMetric::Area; + case vtkm::filter::CellMetric::ASPECT_GAMMA: + return vtkm::filter::mesh_info::CellMetric::AspectGama; + case vtkm::filter::CellMetric::ASPECT_RATIO: + return vtkm::filter::mesh_info::CellMetric::AspectRatio; + case vtkm::filter::CellMetric::CONDITION: + return vtkm::filter::mesh_info::CellMetric::Condition; + case vtkm::filter::CellMetric::DIAGONAL_RATIO: + return vtkm::filter::mesh_info::CellMetric::DiagonalRatio; + case vtkm::filter::CellMetric::DIMENSION: + return vtkm::filter::mesh_info::CellMetric::Dimension; + case vtkm::filter::CellMetric::JACOBIAN: + return vtkm::filter::mesh_info::CellMetric::Jacobian; + case vtkm::filter::CellMetric::MAX_ANGLE: + return vtkm::filter::mesh_info::CellMetric::MaxAngle; + case vtkm::filter::CellMetric::MAX_DIAGONAL: + return vtkm::filter::mesh_info::CellMetric::MaxDiagonal; + case vtkm::filter::CellMetric::MIN_ANGLE: + return vtkm::filter::mesh_info::CellMetric::MinAngle; + case vtkm::filter::CellMetric::MIN_DIAGONAL: + return vtkm::filter::mesh_info::CellMetric::MinDiagonal; + case vtkm::filter::CellMetric::ODDY: + return vtkm::filter::mesh_info::CellMetric::Oddy; + case vtkm::filter::CellMetric::RELATIVE_SIZE_SQUARED: + return vtkm::filter::mesh_info::CellMetric::RelativeSizeSquared; + case vtkm::filter::CellMetric::SCALED_JACOBIAN: + return vtkm::filter::mesh_info::CellMetric::ScaledJacobian; + case vtkm::filter::CellMetric::SHAPE: + return vtkm::filter::mesh_info::CellMetric::Shape; + case vtkm::filter::CellMetric::SHAPE_AND_SIZE: + return vtkm::filter::mesh_info::CellMetric::ShapeAndSize; + case vtkm::filter::CellMetric::SHEAR: + return vtkm::filter::mesh_info::CellMetric::Shear; + case vtkm::filter::CellMetric::SKEW: + return vtkm::filter::mesh_info::CellMetric::Skew; + case vtkm::filter::CellMetric::STRETCH: + return vtkm::filter::mesh_info::CellMetric::Stretch; + case vtkm::filter::CellMetric::TAPER: + return vtkm::filter::mesh_info::CellMetric::Taper; + case vtkm::filter::CellMetric::VOLUME: + return vtkm::filter::mesh_info::CellMetric::Volume; + case vtkm::filter::CellMetric::WARPAGE: + return vtkm::filter::mesh_info::CellMetric::Warpage; + default: + throw vtkm::cont::ErrorBadValue("Invalid mesh quality metric."); + } +} + +VTKM_DEPRECATED_SUPPRESS_END + +} // namespace filter +} // namespace vtkm diff --git a/vtkm/filter/mesh_info/MeshQuality.h b/vtkm/filter/mesh_info/MeshQuality.h index 6596388a7..1a25e903c 100644 --- a/vtkm/filter/mesh_info/MeshQuality.h +++ b/vtkm/filter/mesh_info/MeshQuality.h @@ -30,9 +30,81 @@ namespace filter { namespace mesh_info { -//Different cell metrics available to use -//This must follow the same order as the MetricNames above -enum class CellMetric + +enum struct CellMetric +{ + Area, + AspectGama, + AspectRatio, + Condition, + DiagonalRatio, + Dimension, + Jacobian, + MaxAngle, + MaxDiagonal, + MinAngle, + MinDiagonal, + Oddy, + RelativeSizeSquared, + ScaledJacobian, + Shape, + ShapeAndSize, + Shear, + Skew, + Stretch, + Taper, + Volume, + Warpage, + None +}; + +/** \brief Computes the quality of an unstructured cell-based mesh. The quality is defined in terms of the + * summary statistics (frequency, mean, variance, min, max) of metrics computed over the mesh + * cells. One of several different metrics can be specified for a given cell type, and the mesh + * can consist of one or more different cell types. The resulting mesh quality is stored as one + * or more new fields in the output dataset of this filter, with a separate field for each cell type. + * Each field contains the metric summary statistics for the cell type. + * Summary statists with all 0 values imply that the specified metric does not support the cell type. + */ +class VTKM_FILTER_MESH_INFO_EXPORT MeshQuality : public vtkm::filter::NewFilterField +{ +public: + VTKM_CONT explicit MeshQuality(CellMetric); + +private: + VTKM_CONT vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; + + CellMetric MyMetric; +}; +} // namespace mesh_info + +VTKM_DEPRECATED_SUPPRESS_BEGIN +VTKM_DEPRECATED(1.8) +static const std::string MetricNames[] = { "area", + "aspectGamma", + "aspectRatio", + "condition", + "diagonalRatio", + "dimension", + "jacobian", + "maxAngle", + "maxDiagonal", + "minAngle", + "minDiagonal", + "oddy", + "relativeSizeSquared", + "scaledJacobian", + "shape", + "shapeAndSize", + "shear", + "skew", + "stretch", + "taper", + "volume", + "warpage" }; +VTKM_DEPRECATED_SUPPRESS_END + +enum struct VTKM_DEPRECATED(1.8 "Use vtkm::filter::mesh_info::CellMetric.") CellMetric { AREA, ASPECT_GAMMA, @@ -60,25 +132,24 @@ enum class CellMetric EMPTY }; -/** \brief Computes the quality of an unstructured cell-based mesh. The quality is defined in terms of the - * summary statistics (frequency, mean, variance, min, max) of metrics computed over the mesh - * cells. One of several different metrics can be specified for a given cell type, and the mesh - * can consist of one or more different cell types. The resulting mesh quality is stored as one - * or more new fields in the output dataset of this filter, with a separate field for each cell type. - * Each field contains the metric summary statistics for the cell type. - * Summary statists with all 0 values imply that the specified metric does not support the cell type. - */ -class VTKM_FILTER_MESH_INFO_EXPORT MeshQuality : public vtkm::filter::NewFilterField +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::mesh_info::MeshQuality.") MeshQuality + : public vtkm::filter::mesh_info::MeshQuality { + VTKM_DEPRECATED_SUPPRESS_BEGIN + static vtkm::filter::mesh_info::CellMetric ConvertCellMetric( + vtkm::filter::CellMetric oldMetricEnum); + VTKM_DEPRECATED_SUPPRESS_END + public: - VTKM_CONT explicit MeshQuality(CellMetric); + using mesh_info::MeshQuality::MeshQuality; -private: - VTKM_CONT vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; - - CellMetric MyMetric; + VTKM_DEPRECATED_SUPPRESS_BEGIN + MeshQuality(vtkm::filter::CellMetric oldMetric) + : mesh_info::MeshQuality(ConvertCellMetric(oldMetric)) + { + } + VTKM_DEPRECATED_SUPPRESS_END }; -} // namespace mesh_info } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/mesh_info/testing/UnitTestMeshQualityFilter.cxx b/vtkm/filter/mesh_info/testing/UnitTestMeshQualityFilter.cxx index 3b870ceb0..64c03b4a8 100644 --- a/vtkm/filter/mesh_info/testing/UnitTestMeshQualityFilter.cxx +++ b/vtkm/filter/mesh_info/testing/UnitTestMeshQualityFilter.cxx @@ -196,157 +196,157 @@ int TestMeshQuality() std::vector inputs; expectedValues.push_back(FloatVec{ 0, 0, 1, 1.333333333f, 4, 4 }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::VOLUME); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::Volume); metricName.emplace_back("volume"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ 3, 4, 0, 0, 0, 0 }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::AREA); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::Area); metricName.emplace_back("area"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ 3, 1 }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::AREA); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::Area); metricName.emplace_back("area"); inputs.push_back(singleTypeInput); expectedValues.push_back(FloatVec{ 1.164010f, 1.118034f, 1.648938f, 0, 0, 1.1547f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::ASPECT_RATIO); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::AspectRatio); metricName.emplace_back("aspectRatio"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ 1.164010f, 2.47582f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::ASPECT_RATIO); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::AspectRatio); metricName.emplace_back("aspectRatio"); inputs.push_back(singleTypeInput); expectedValues.push_back(FloatVec{ 0, 0, 1.52012f, 0, 0, 0 }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::ASPECT_GAMMA); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::AspectGama); metricName.emplace_back("aspectGamma"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ 1.058475f, 2.25f, 1.354007f, 0, 0, 1.563472f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::CONDITION); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::Condition); metricName.emplace_back("condition"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ 1.058475f, 2.02073f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::CONDITION); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::Condition); metricName.emplace_back("condition"); inputs.push_back(singleTypeInput); expectedValues.push_back(FloatVec{ 45, 45, -1, -1, -1, -1 }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::MIN_ANGLE); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::MinAngle); metricName.emplace_back("minAngle"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ 45, 18.4348f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::MIN_ANGLE); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::MinAngle); metricName.emplace_back("minAngle"); inputs.push_back(singleTypeInput); expectedValues.push_back(FloatVec{ 71.56505f, 135, -1, -1, -1, -1 }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::MAX_ANGLE); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::MaxAngle); metricName.emplace_back("maxAngle"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ 71.56505f, 116.565f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::MAX_ANGLE); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::MaxAngle); metricName.emplace_back("maxAngle"); inputs.push_back(singleTypeInput); expectedValues.push_back(FloatVec{ -1, -1, -1, -1, -1, 1.73205f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::MIN_DIAGONAL); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::MinDiagonal); metricName.emplace_back("minDiagonal"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ -1, -1, -1, -1, -1, 4.3589f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::MAX_DIAGONAL); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::MaxDiagonal); metricName.emplace_back("maxDiagonal"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ 0, 2, 6, 0, 0, 4 }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::JACOBIAN); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::Jacobian); metricName.emplace_back("jacobian"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ 0.816497f, 0.707107f, 0.408248f, -2, -2, 0.57735f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::SCALED_JACOBIAN); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::ScaledJacobian); metricName.emplace_back("scaledJacobian"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ 0.816497f, 0.365148f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::SCALED_JACOBIAN); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::ScaledJacobian); metricName.emplace_back("scaledJacobian"); inputs.push_back(singleTypeInput); expectedValues.push_back(FloatVec{ -1, 8.125f, -1, -1, -1, 2.62484f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::ODDY); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::Oddy); metricName.emplace_back("oddy"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ -1, 0.620174f, -1, -1, -1, 0.397360f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::DIAGONAL_RATIO); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::DiagonalRatio); metricName.emplace_back("diagonalRatio"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ 0.944755f, 0.444444f, 0.756394f, -1, -1, 0.68723f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::SHAPE); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::Shape); metricName.emplace_back("shape"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ 0.944755f, 0.494872f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::SHAPE); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::Shape); metricName.emplace_back("shape"); inputs.push_back(singleTypeInput); expectedValues.push_back(FloatVec{ -1, 0.707107f, -1, -1, -1, 0.57735f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::SHEAR); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::Shear); metricName.emplace_back("shear"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ -1, 0.447214f, -1, -1, -1, 0.57735f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::SKEW); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::Skew); metricName.emplace_back("skew"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ -1, (float)0.392232, -1, -1, -1, (float)0.688247 }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::STRETCH); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::Stretch); metricName.emplace_back("stretch"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ -1, 0.5, -1, -1, -1, 0 }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::TAPER); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::Taper); metricName.emplace_back("taper"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ -1, 1, -1, -1, -1, -1 }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::WARPAGE); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::Warpage); metricName.emplace_back("warpage"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ -1, -1, -1, -1, -1, 0.707107f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::DIMENSION); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::Dimension); metricName.emplace_back("dimension"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ 0.151235f, 0.085069f, 0.337149f, -1, -1, 0.185378f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::RELATIVE_SIZE_SQUARED); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::RelativeSizeSquared); metricName.emplace_back("relativeSizeSquared"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ 0.444444f, 0.25f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::RELATIVE_SIZE_SQUARED); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::RelativeSizeSquared); metricName.emplace_back("relativeSizeSquared"); inputs.push_back(singleTypeInput); expectedValues.push_back(FloatVec{ 0.142880f, 0.037809f, 0.255017f, -1, -1, 0.127397f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::SHAPE_AND_SIZE); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::ShapeAndSize); metricName.emplace_back("shapeAndSize"); inputs.push_back(explicitInput); expectedValues.push_back(FloatVec{ 0.419891f, 0.123718f }); - metrics.push_back(vtkm::filter::mesh_info::CellMetric::SHAPE_AND_SIZE); + metrics.push_back(vtkm::filter::mesh_info::CellMetric::ShapeAndSize); metricName.emplace_back("shapeAndSize"); inputs.push_back(singleTypeInput); diff --git a/vtkm/filter/mesh_info/worklet/CellMeasure.h b/vtkm/filter/mesh_info/worklet/CellMeasure.h index 852adcc59..d0f5f9b0a 100644 --- a/vtkm/filter/mesh_info/worklet/CellMeasure.h +++ b/vtkm/filter/mesh_info/worklet/CellMeasure.h @@ -84,19 +84,19 @@ private: // Fall through to return 0 measure. break; case 1: - if (this->measure & IntegrationType::ArcLength) + if ((this->measure & IntegrationType::ArcLength) == IntegrationType::ArcLength) { return vtkm::exec::CellMeasure(numPts, pts, CellShapeType(), ec); } break; case 2: - if (this->measure & IntegrationType::Area) + if ((this->measure & IntegrationType::Area) == IntegrationType::Area) { return vtkm::exec::CellMeasure(numPts, pts, CellShapeType(), ec); } break; case 3: - if (this->measure & IntegrationType::Volume) + if ((this->measure & IntegrationType::Volume) == IntegrationType::Volume) { return vtkm::exec::CellMeasure(numPts, pts, CellShapeType(), ec); } diff --git a/vtkm/filter/mesh_info/worklet/MeshQuality.h b/vtkm/filter/mesh_info/worklet/MeshQuality.h index 118781597..fa756c340 100644 --- a/vtkm/filter/mesh_info/worklet/MeshQuality.h +++ b/vtkm/filter/mesh_info/worklet/MeshQuality.h @@ -96,7 +96,7 @@ public: private: // data member - vtkm::filter::mesh_info::CellMetric Metric{ vtkm::filter::mesh_info::CellMetric::EMPTY }; + vtkm::filter::mesh_info::CellMetric Metric{ vtkm::filter::mesh_info::CellMetric::None }; vtkm::FloatDefault AverageArea{}; vtkm::FloatDefault AverageVolume{}; @@ -116,92 +116,92 @@ private: vtkm::ErrorCode ec{ vtkm::ErrorCode::Success }; switch (this->Metric) { - case vtkm::filter::mesh_info::CellMetric::AREA: + case vtkm::filter::mesh_info::CellMetric::Area: metricValue = vtkm::exec::CellMeasure(numPts, pts, tag, ec); if (dims != 2) metricValue = 0.; break; - case vtkm::filter::mesh_info::CellMetric::ASPECT_GAMMA: + case vtkm::filter::mesh_info::CellMetric::AspectGama: metricValue = vtkm::worklet::cellmetrics::CellAspectGammaMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::ASPECT_RATIO: + case vtkm::filter::mesh_info::CellMetric::AspectRatio: metricValue = vtkm::worklet::cellmetrics::CellAspectRatioMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::CONDITION: + case vtkm::filter::mesh_info::CellMetric::Condition: metricValue = vtkm::worklet::cellmetrics::CellConditionMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::DIAGONAL_RATIO: + case vtkm::filter::mesh_info::CellMetric::DiagonalRatio: metricValue = vtkm::worklet::cellmetrics::CellDiagonalRatioMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::DIMENSION: + case vtkm::filter::mesh_info::CellMetric::Dimension: metricValue = vtkm::worklet::cellmetrics::CellDimensionMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::JACOBIAN: + case vtkm::filter::mesh_info::CellMetric::Jacobian: metricValue = vtkm::worklet::cellmetrics::CellJacobianMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::MAX_ANGLE: + case vtkm::filter::mesh_info::CellMetric::MaxAngle: metricValue = vtkm::worklet::cellmetrics::CellMaxAngleMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::MAX_DIAGONAL: + case vtkm::filter::mesh_info::CellMetric::MaxDiagonal: metricValue = vtkm::worklet::cellmetrics::CellMaxDiagonalMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::MIN_ANGLE: + case vtkm::filter::mesh_info::CellMetric::MinAngle: metricValue = vtkm::worklet::cellmetrics::CellMinAngleMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::MIN_DIAGONAL: + case vtkm::filter::mesh_info::CellMetric::MinDiagonal: metricValue = vtkm::worklet::cellmetrics::CellMinDiagonalMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::ODDY: + case vtkm::filter::mesh_info::CellMetric::Oddy: metricValue = vtkm::worklet::cellmetrics::CellOddyMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::RELATIVE_SIZE_SQUARED: + case vtkm::filter::mesh_info::CellMetric::RelativeSizeSquared: metricValue = vtkm::worklet::cellmetrics::CellRelativeSizeSquaredMetric( numPts, pts, static_cast(average), tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::SHAPE_AND_SIZE: + case vtkm::filter::mesh_info::CellMetric::ShapeAndSize: metricValue = vtkm::worklet::cellmetrics::CellShapeAndSizeMetric( numPts, pts, static_cast(average), tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::SCALED_JACOBIAN: + case vtkm::filter::mesh_info::CellMetric::ScaledJacobian: metricValue = vtkm::worklet::cellmetrics::CellScaledJacobianMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::SHAPE: + case vtkm::filter::mesh_info::CellMetric::Shape: metricValue = vtkm::worklet::cellmetrics::CellShapeMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::SHEAR: + case vtkm::filter::mesh_info::CellMetric::Shear: metricValue = vtkm::worklet::cellmetrics::CellShearMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::SKEW: + case vtkm::filter::mesh_info::CellMetric::Skew: metricValue = vtkm::worklet::cellmetrics::CellSkewMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::STRETCH: + case vtkm::filter::mesh_info::CellMetric::Stretch: metricValue = vtkm::worklet::cellmetrics::CellStretchMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::TAPER: + case vtkm::filter::mesh_info::CellMetric::Taper: metricValue = vtkm::worklet::cellmetrics::CellTaperMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::VOLUME: + case vtkm::filter::mesh_info::CellMetric::Volume: metricValue = vtkm::exec::CellMeasure(numPts, pts, tag, ec); if (dims != 3) metricValue = 0.; break; - case vtkm::filter::mesh_info::CellMetric::WARPAGE: + case vtkm::filter::mesh_info::CellMetric::Warpage: metricValue = vtkm::worklet::cellmetrics::CellWarpageMetric(numPts, pts, tag, ec); break; - case vtkm::filter::mesh_info::CellMetric::EMPTY: + case vtkm::filter::mesh_info::CellMetric::None: break; default: //Only call metric function if a metric is specified for this shape type diff --git a/vtkm/filter/vector_analysis/CrossProduct.h b/vtkm/filter/vector_analysis/CrossProduct.h index 06b6f41e8..12ad8dfb0 100644 --- a/vtkm/filter/vector_analysis/CrossProduct.h +++ b/vtkm/filter/vector_analysis/CrossProduct.h @@ -122,8 +122,13 @@ private: VTKM_CONT vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; }; -} -} -} // namespace vtkm::filter::vector_analysis +} // namespace vector_analysis +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::vector_analysis::CrossProduct.") CrossProduct + : public vtkm::filter::vector_analysis::CrossProduct +{ + using vector_analysis::CrossProduct::CrossProduct; +}; +} // namespace filter +} // namespace vtkm #endif // vtk_m_filter_vector_analysis_CrossProduct_h diff --git a/vtkm/filter/vector_analysis/DotProduct.h b/vtkm/filter/vector_analysis/DotProduct.h index bf84cb7f2..96830cf3f 100644 --- a/vtkm/filter/vector_analysis/DotProduct.h +++ b/vtkm/filter/vector_analysis/DotProduct.h @@ -122,6 +122,11 @@ private: vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; }; } // namespace vector_analysis +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::vector_analysis::DotProduct.") DotProduct + : public vtkm::filter::vector_analysis::DotProduct +{ + using vector_analysis::DotProduct::DotProduct; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/vector_analysis/Gradient.h b/vtkm/filter/vector_analysis/Gradient.h index 527fe8a8e..e971c2dba 100644 --- a/vtkm/filter/vector_analysis/Gradient.h +++ b/vtkm/filter/vector_analysis/Gradient.h @@ -104,6 +104,11 @@ private: }; } // namespace vector_analysis +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::vector_analysis::Gradient.") Gradient + : public vtkm::filter::vector_analysis::Gradient +{ + using vector_analysis::Gradient::Gradient; +}; } // namespace filter } // namespace vtkm::filter diff --git a/vtkm/filter/vector_analysis/SurfaceNormals.h b/vtkm/filter/vector_analysis/SurfaceNormals.h index 95feac613..821d1f866 100644 --- a/vtkm/filter/vector_analysis/SurfaceNormals.h +++ b/vtkm/filter/vector_analysis/SurfaceNormals.h @@ -107,8 +107,13 @@ private: std::string CellNormalsName; std::string PointNormalsName; }; -} -} -} // vtkm::filter +} // namespace vector_analysis +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::vector_analysis::SurfaceNormals.") SurfaceNormals + : public vtkm::filter::vector_analysis::SurfaceNormals +{ + using vector_analysis::SurfaceNormals::SurfaceNormals; +}; +} // namespace filter +} // namespace vtkm #endif // vtk_m_filter_vector_analysis_SurfaceNormal_h diff --git a/vtkm/filter/vector_analysis/VectorMagnitude.h b/vtkm/filter/vector_analysis/VectorMagnitude.h index 9d4c0b7c2..9de73a729 100644 --- a/vtkm/filter/vector_analysis/VectorMagnitude.h +++ b/vtkm/filter/vector_analysis/VectorMagnitude.h @@ -29,6 +29,11 @@ private: VTKM_CONT vtkm::cont::DataSet DoExecute(const vtkm::cont::DataSet& input) override; }; } // namespace vector_analysis +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::vector_analysis::VectorMagnitude.") VectorMagnitude + : public vtkm::filter::vector_analysis::VectorMagnitude +{ + using vector_analysis::VectorMagnitude::VectorMagnitude; +}; } // namespace filter } // namespace vtkm::filter diff --git a/vtkm/filter/zfp/ZFPCompressor1D.h b/vtkm/filter/zfp/ZFPCompressor1D.h index a02e37cdf..dbdfbdd16 100644 --- a/vtkm/filter/zfp/ZFPCompressor1D.h +++ b/vtkm/filter/zfp/ZFPCompressor1D.h @@ -38,6 +38,11 @@ private: vtkm::Float64 rate = 0; }; } // namespace zfp +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::zfp::ZFPCompressor1D.") ZFPCompressor1D + : public vtkm::filter::zfp::ZFPCompressor1D +{ + using zfp::ZFPCompressor1D::ZFPCompressor1D; +}; } // namespace filter } // namespace vtkm::filter diff --git a/vtkm/filter/zfp/ZFPCompressor2D.h b/vtkm/filter/zfp/ZFPCompressor2D.h index 468db08e0..df1e8f7c5 100644 --- a/vtkm/filter/zfp/ZFPCompressor2D.h +++ b/vtkm/filter/zfp/ZFPCompressor2D.h @@ -38,6 +38,11 @@ private: vtkm::Float64 rate = 0; }; } // namespace zfp +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::zfp::ZFPCompressor2D.") ZFPCompressor2D + : public vtkm::filter::zfp::ZFPCompressor2D +{ + using zfp::ZFPCompressor2D::ZFPCompressor2D; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/zfp/ZFPCompressor3D.h b/vtkm/filter/zfp/ZFPCompressor3D.h index 783cb9f7b..2adf3f80f 100644 --- a/vtkm/filter/zfp/ZFPCompressor3D.h +++ b/vtkm/filter/zfp/ZFPCompressor3D.h @@ -37,8 +37,13 @@ private: vtkm::Float64 rate = 0; }; -} -} -} // namespace vtkm::filter +} // namespace zfp +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::zfp::ZFPCompressor3D.") ZFPCompressor3D + : public vtkm::filter::zfp::ZFPCompressor3D +{ + using zfp::ZFPCompressor3D::ZFPCompressor3D; +}; +} // namespace filter +} // namespace vtkm #endif // vtk_m_filter_zfp_ZFPCompressor3D_h diff --git a/vtkm/filter/zfp/ZFPDecompressor1D.h b/vtkm/filter/zfp/ZFPDecompressor1D.h index 4283e4cb9..3ef5bcb72 100644 --- a/vtkm/filter/zfp/ZFPDecompressor1D.h +++ b/vtkm/filter/zfp/ZFPDecompressor1D.h @@ -38,6 +38,11 @@ private: vtkm::Float64 rate = 0; }; } // namespace zfp +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::zfp::ZFPDecompressor1D.") ZFPDecompressor1D + : public vtkm::filter::zfp::ZFPDecompressor1D +{ + using zfp::ZFPDecompressor1D::ZFPDecompressor1D; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/zfp/ZFPDecompressor2D.h b/vtkm/filter/zfp/ZFPDecompressor2D.h index bda18ed84..4aaa0f4e5 100644 --- a/vtkm/filter/zfp/ZFPDecompressor2D.h +++ b/vtkm/filter/zfp/ZFPDecompressor2D.h @@ -38,6 +38,11 @@ private: vtkm::Float64 rate = 0; }; } // namespace zfp +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::zfp::ZFPDecompressor2D.") ZFPDecompressor2D + : public vtkm::filter::zfp::ZFPDecompressor2D +{ + using zfp::ZFPDecompressor2D::ZFPDecompressor2D; +}; } // namespace filter } // namespace vtkm diff --git a/vtkm/filter/zfp/ZFPDecompressor3D.h b/vtkm/filter/zfp/ZFPDecompressor3D.h index 8245e6f34..19c6b05bd 100644 --- a/vtkm/filter/zfp/ZFPDecompressor3D.h +++ b/vtkm/filter/zfp/ZFPDecompressor3D.h @@ -38,6 +38,11 @@ private: vtkm::Float64 rate = 0; }; } // namespace zfp +class VTKM_DEPRECATED(1.8, "Use vtkm::filter::zfp::ZFPDecompressor3D.") ZFPDecompressor3D + : public vtkm::filter::zfp::ZFPDecompressor3D +{ + using zfp::ZFPDecompressor3D::ZFPDecompressor3D; +}; } // namespace filter } // namespace vtkm