Merge topic 'consistent_temporal_advection_example'

5a2c2b946 temporaladvection example follows the same naming pattern as all examples

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Abhishek Yenpure <abhishek@uoregon.edu>
Merge-request: !1245
This commit is contained in:
Robert Maynard 2018-06-01 16:35:12 +00:00 committed by Kitware Robot
commit 84fc7520c6
6 changed files with 14 additions and 19 deletions

@ -34,7 +34,7 @@ add_subdirectory(histogram)
add_subdirectory(isosurface)
add_subdirectory(multi_backend)
add_subdirectory(particle_advection)
add_subdirectory(temporaladvection)
add_subdirectory(temporal_advection)
add_subdirectory(redistribute_points)
add_subdirectory(rendering)
add_subdirectory(streamline)

@ -23,4 +23,3 @@
#define __BUILDING_TBB_VERSION__
#include "ParticleAdvection.cxx"
#include <tbb/task_scheduler_init.h>

@ -22,20 +22,20 @@
#Find the VTK-m package
cmake_minimum_required(VERSION 3.3 FATAL_ERROR)
project(ParticleAdvection CXX)
project(TemporalAdvection CXX)
#Find the VTK-m package
find_package(VTKm REQUIRED QUIET)
add_executable(exeserial ParticleAdvection.cxx)
target_link_libraries(exeserial PRIVATE vtkm_cont)
add_executable(Temporal_Advection_SERIAL TemporalAdvection.cxx)
target_link_libraries(Temporal_Advection_SERIAL PRIVATE vtkm_cont)
if(TARGET vtkm::tbb)
add_executable(exetbb ParticleAdvectionTBB.cxx)
target_link_libraries(exetbb PRIVATE vtkm_cont)
add_executable(Temporal_Advection_TBB TemporalAdvectionTBB.cxx)
target_link_libraries(Temporal_Advection_TBB PRIVATE vtkm_cont)
endif()
if(TARGET vtkm::cuda)
add_executable(execuda ParticleAdvection.cu)
target_link_libraries(execuda PRIVATE vtkm_cont)
add_executable(Temporal_Advection_CUDA TemporalAdvection.cu)
target_link_libraries(Temporal_Advection_CUDA PRIVATE vtkm_cont)
endif()

@ -20,4 +20,4 @@
#define VTKM_DEVICE_ADAPTER VTKM_DEVICE_ADAPTER_CUDA
#include "ParticleAdvection.cxx"
#include "TemporalAdvection.cxx"

@ -38,11 +38,11 @@
// The way to verify if the code produces correct streamlines
// is to do a visual test by using VisIt/ParaView to visualize
// the file written by this method.
int renderAndWriteDataSet(vtkm::cont::DataSet& dataset)
int renderAndWriteDataSet(const vtkm::cont::DataSet& dataset)
{
std::cout << "Trying to render the dataset" << std::endl;
vtkm::io::writer::VTKDataSetWriter writer("pathlines.vtk");
writer.WriteDataSet(dataset, static_cast<vtkm::Id>(0));
writer.WriteDataSet(dataset);
return 0;
}
@ -62,7 +62,6 @@ void RunTest(vtkm::Id numSteps, vtkm::Float32 stepSize, vtkm::Id advectType)
// as VTKm evolves.
vtkm::cont::ArrayHandle<vtkm::Vec<FieldType, 3>> fieldArray1;
vtkm::cont::ArrayHandle<vtkm::Vec<FieldType, 3>> fieldArray2;
vtkm::Id numValues;
vtkm::io::reader::BOVDataSetReader reader1("slice1.bov");
vtkm::cont::DataSet ds1 = reader1.ReadDataSet();
@ -94,7 +93,7 @@ void RunTest(vtkm::Id numSteps, vtkm::Float32 stepSize, vtkm::Id advectType)
// This example does not work on scale, works on basic 11 particles
// so the results are more tractible
std::vector<vtkm::Vec<FieldType, 3>> seeds;
vtkm::Id x = 0, y = 5, z = 0;
FieldType x = 0, y = 5, z = 0;
for (int i = 0; i <= 11; i++)
{
vtkm::Vec<FieldType, 3> point;
@ -138,7 +137,7 @@ int main(int argc, char** argv)
}
numSteps = atoi(argv[1]);
stepSize = atof(argv[2]);
stepSize = static_cast<vtkm::Float32>(atof(argv[2]));
advectionType = atoi(argv[3]);
RunTest(numSteps, stepSize, advectionType);

@ -20,7 +20,4 @@
#define VTKM_DEVICE_ADAPTER VTKM_DEVICE_ADAPTER_TBB
#define __BUILDING_TBB_VERSION__
#include "ParticleAdvection.cxx"
#include <tbb/task_scheduler_init.h>
#include "TemporalAdvection.cxx"