//============================================================================ // 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_ParticleAdvection_hxx #define vtk_m_filter_ParticleAdvection_hxx #include #include #include #include #include namespace vtkm { namespace filter { //----------------------------------------------------------------------------- template inline VTKM_CONT ParticleAdvectionBase::ParticleAdvectionBase() : vtkm::filter::FilterParticleAdvection, ParticleType>() { } //----------------------------------------------------------------------------- template template inline VTKM_CONT vtkm::cont::PartitionedDataSet ParticleAdvectionBase::PrepareForExecution( const vtkm::cont::PartitionedDataSet& input, const vtkm::filter::PolicyBase&) { using AlgorithmType = vtkm::filter::particleadvection::ParticleAdvectionAlgorithm; using ThreadedAlgorithmType = vtkm::filter::particleadvection::ParticleAdvectionThreadedAlgorithm; using DSIType = vtkm::filter::particleadvection::DataSetIntegrator; this->ValidateOptions(); vtkm::filter::particleadvection::BoundsMap boundsMap(input); auto dsi = this->CreateDataSetIntegrators(input, boundsMap); if (this->GetUseThreadedAlgorithm()) return vtkm::filter::particleadvection::RunAlgo( boundsMap, dsi, this->NumberOfSteps, this->StepSize, this->Seeds); else return vtkm::filter::particleadvection::RunAlgo( boundsMap, dsi, this->NumberOfSteps, this->StepSize, this->Seeds); } } } // namespace vtkm::filter #endif