Commit ac76fe16 authored by Kitware Robot's avatar Kitware Robot Committed by Ben Boeckel

clang-format: reformat using clang-format-8

Run the `clang-format.bash` script to update all our C and C++ code to a
new style defined by `.clang-format`.  Use `clang-format` version 8.0.

* If you reached this commit for a line in `git blame`, re-run the blame
  operation starting at the parent of this commit to see older history
  for the content.

* See the parent commit for instructions to rebase a change across this
  style transition commit.
parent 8118ae5c

Too many changes to show.

To preserve performance only 1000 of 1000+ files are displayed.
...@@ -25,8 +25,7 @@ ...@@ -25,8 +25,7 @@
#include "vtkRenderWindowInteractor.h" #include "vtkRenderWindowInteractor.h"
#include "vtkRenderer.h" #include "vtkRenderer.h"
int TestVTKMCleanGrid(int argc, char* argv[])
int TestVTKMCleanGrid(int argc, char *argv[])
{ {
vtkNew<vtkRTAnalyticSource> wavelet; vtkNew<vtkRTAnalyticSource> wavelet;
wavelet->SetWholeExtent(-10, 10, -10, 10, -10, 10); wavelet->SetWholeExtent(-10, 10, -10, 10, -10, 10);
......
...@@ -32,10 +32,11 @@ ...@@ -32,10 +32,11 @@
#include "vtkSphereSource.h" #include "vtkSphereSource.h"
#include "vtkUnstructuredGrid.h" #include "vtkUnstructuredGrid.h"
namespace { namespace
{
template <typename DataSetT> template <typename DataSetT>
void GenerateScalars(DataSetT *dataset, bool negate) void GenerateScalars(DataSetT* dataset, bool negate)
{ {
vtkIdType numPoints = dataset->GetNumberOfPoints(); vtkIdType numPoints = dataset->GetNumberOfPoints();
...@@ -48,8 +49,7 @@ void GenerateScalars(DataSetT *dataset, bool negate) ...@@ -48,8 +49,7 @@ void GenerateScalars(DataSetT *dataset, bool negate)
for (vtkIdType i = 0; i < numPoints; ++i) for (vtkIdType i = 0; i < numPoints; ++i)
{ {
dataset->GetPoint(i, point); dataset->GetPoint(i, point);
scalars->SetTypedComponent(i, 0, (negate ?-point[0] - point[1] scalars->SetTypedComponent(i, 0, (negate ? -point[0] - point[1] : point[0] + point[1]));
: point[0] + point[1]));
} }
dataset->GetPointData()->SetScalars(scalars); dataset->GetPointData()->SetScalars(scalars);
} }
...@@ -66,7 +66,7 @@ int TestVTKMClip(int, char*[]) ...@@ -66,7 +66,7 @@ int TestVTKMClip(int, char*[])
sphereSource->SetThetaResolution(50); sphereSource->SetThetaResolution(50);
sphereSource->SetPhiResolution(50); sphereSource->SetPhiResolution(50);
sphereSource->Update(); sphereSource->Update();
vtkPolyData *sphere = sphereSource->GetOutput(); vtkPolyData* sphere = sphereSource->GetOutput();
GenerateScalars(sphere, false); GenerateScalars(sphere, false);
// Clip at zero: // Clip at zero:
...@@ -104,7 +104,7 @@ int TestVTKMClip(int, char*[]) ...@@ -104,7 +104,7 @@ int TestVTKMClip(int, char*[])
vtkNew<vtkDelaunay3D> tetrahedralizer; vtkNew<vtkDelaunay3D> tetrahedralizer;
tetrahedralizer->SetInputConnection(imageToPoints->GetOutputPort()); tetrahedralizer->SetInputConnection(imageToPoints->GetOutputPort());
tetrahedralizer->Update(); tetrahedralizer->Update();
vtkUnstructuredGrid *tets = tetrahedralizer->GetOutput(); vtkUnstructuredGrid* tets = tetrahedralizer->GetOutput();
GenerateScalars(tets, true); GenerateScalars(tets, true);
// Clip at zero: // Clip at zero:
...@@ -129,7 +129,7 @@ int TestVTKMClip(int, char*[]) ...@@ -129,7 +129,7 @@ int TestVTKMClip(int, char*[])
renderer->AddActor(tetActor); renderer->AddActor(tetActor);
// Third dataset tests imagedata. This should produce an unstructured grid: // Third dataset tests imagedata. This should produce an unstructured grid:
vtkImageData *image = imageSource->GetOutput(); vtkImageData* image = imageSource->GetOutput();
GenerateScalars(image, false); GenerateScalars(image, false);
vtkNew<vtkmClip> imageClipper; vtkNew<vtkmClip> imageClipper;
...@@ -159,10 +159,10 @@ int TestVTKMClip(int, char*[]) ...@@ -159,10 +159,10 @@ int TestVTKMClip(int, char*[])
iren->SetRenderWindow(renWin); iren->SetRenderWindow(renWin);
renWin->AddRenderer(renderer); renWin->AddRenderer(renderer);
renWin->SetSize(500,500); renWin->SetSize(500, 500);
renderer->GetActiveCamera()->SetPosition(0,0,1); renderer->GetActiveCamera()->SetPosition(0, 0, 1);
renderer->GetActiveCamera()->SetFocalPoint(0,0,0); renderer->GetActiveCamera()->SetFocalPoint(0, 0, 0);
renderer->GetActiveCamera()->SetViewUp(0,1,0); renderer->GetActiveCamera()->SetViewUp(0, 1, 0);
renderer->ResetCamera(); renderer->ResetCamera();
renWin->Render(); renWin->Render();
......
...@@ -28,7 +28,6 @@ ...@@ -28,7 +28,6 @@
#include "vtkRenderer.h" #include "vtkRenderer.h"
#include "vtkSphere.h" #include "vtkSphere.h"
int TestVTKMClipWithImplicitFunction(int argc, char* argv[]) int TestVTKMClipWithImplicitFunction(int argc, char* argv[])
{ {
vtkNew<vtkRTAnalyticSource> wavelet; vtkNew<vtkRTAnalyticSource> wavelet;
......
...@@ -19,7 +19,8 @@ ...@@ -19,7 +19,8 @@
#include "vtkPolyData.h" #include "vtkPolyData.h"
#include "vtkSmartPointer.h" #include "vtkSmartPointer.h"
namespace { namespace
{
const double pi = 3.14159265358979323846264338327950288; const double pi = 3.14159265358979323846264338327950288;
const double twoPi = 6.28318530717958647692528676655900576; const double twoPi = 6.28318530717958647692528676655900576;
const int dim = 5; const int dim = 5;
...@@ -28,20 +29,20 @@ const double tolerance = 0.0001; ...@@ -28,20 +29,20 @@ const double tolerance = 0.0001;
bool ArePointsWithinTolerance(double v1, double v2) bool ArePointsWithinTolerance(double v1, double v2)
{ {
if(v1 == v2 || fabs(v1)+fabs(v2) < tolerance) if (v1 == v2 || fabs(v1) + fabs(v2) < tolerance)
{ {
return true; return true;
} }
if(v1 == 0.0) if (v1 == 0.0)
{ {
if(fabs(v2) < tolerance) if (fabs(v2) < tolerance)
{ {
return true; return true;
} }
return false; return false;
} }
if(fabs(fabs(v1) - fabs(v2)) < tolerance) if (fabs(fabs(v1) - fabs(v2)) < tolerance)
{ {
return true; return true;
} }
...@@ -65,14 +66,12 @@ void MakeTestDataSet(vtkPolyData* pd, const CoordinateType& coordType) ...@@ -65,14 +66,12 @@ void MakeTestDataSet(vtkPolyData* pd, const CoordinateType& coordType)
{ {
for (vtkIdType i = 0; i < dim; ++i) for (vtkIdType i = 0; i < dim; ++i)
{ {
double z = double z = static_cast<double>(i) / static_cast<double>(dim - 1);
static_cast<double>(i) / static_cast<double>(dim - 1);
for (vtkIdType j = 0; j < dim; ++j) for (vtkIdType j = 0; j < dim; ++j)
{ {
double x = double x = static_cast<double>(j) / static_cast<double>(dim - 1);
static_cast<double>(j) / static_cast<double>(dim - 1);
double y = (x * x + z * z) / 2.0f; double y = (x * x + z * z) / 2.0f;
pcoords->SetTuple3(i*dim + j,x + 0, y + 0, z + 0); pcoords->SetTuple3(i * dim + j, x + 0, y + 0, z + 0);
} }
} }
} }
...@@ -81,67 +80,60 @@ void MakeTestDataSet(vtkPolyData* pd, const CoordinateType& coordType) ...@@ -81,67 +80,60 @@ void MakeTestDataSet(vtkPolyData* pd, const CoordinateType& coordType)
double R = 1.0f; double R = 1.0f;
for (vtkIdType i = 0; i < dim; i++) for (vtkIdType i = 0; i < dim; i++)
{ {
double Z = double Z = static_cast<double>(i) / static_cast<double>(dim - 1);
static_cast<double>(i) / static_cast<double>(dim - 1);
for (vtkIdType j = 0; j < dim; j++) for (vtkIdType j = 0; j < dim; j++)
{ {
double Theta = twoPi * double Theta = twoPi * (static_cast<double>(j) / static_cast<double>(dim - 1));
(static_cast<double>(j) / static_cast<double>(dim - 1)); pcoords->SetTuple3(i * dim + j, R, Theta, Z);
pcoords->SetTuple3(i*dim + j, R, Theta, Z);
} }
} }
} }
else if (coordType == CoordinateType::SPH) else if (coordType == CoordinateType::SPH)
{ {
//Spherical coordinates have some degenerate cases, so provide some good cases. // Spherical coordinates have some degenerate cases, so provide some good cases.
double R = 1.0f; double R = 1.0f;
std::vector<double> Thetas = { std::vector<double> Thetas = { eps, pi / 4, pi / 3, pi / 2, pi - eps };
eps, pi / 4, pi / 3, pi / 2, pi - eps std::vector<double> Phis = { eps, twoPi / 4, twoPi / 3, twoPi / 2, twoPi - eps };
};
std::vector<double> Phis = {
eps, twoPi / 4, twoPi / 3, twoPi / 2, twoPi - eps
};
for (std::size_t i = 0; i < Thetas.size(); i++) for (std::size_t i = 0; i < Thetas.size(); i++)
{ {
for (std::size_t j = 0; j < Phis.size(); j++) for (std::size_t j = 0; j < Phis.size(); j++)
{ {
pcoords->SetTuple3(static_cast<vtkIdType>(i*dim + j), R, Thetas[i], Phis[j]); pcoords->SetTuple3(static_cast<vtkIdType>(i * dim + j), R, Thetas[i], Phis[j]);
} }
} }
} }
pd->GetPoints()->SetData(pcoords); pd->GetPoints()->SetData(pcoords);
} }
void ValidateCoordTransform(vtkPolyData* pd, vtkPolyData* pdTrans, void ValidateCoordTransform(vtkPolyData* pd, vtkPolyData* pdTrans, const std::vector<bool>& isAngle)
const std::vector<bool>& isAngle)
{ {
vtkPoints* pdPoints = pd->GetPoints(); vtkPoints* pdPoints = pd->GetPoints();
vtkPoints* pdTransPoints = pdTrans->GetPoints(); vtkPoints* pdTransPoints = pdTrans->GetPoints();
assert(pdPoints->GetNumberOfPoints() == pdTransPoints->GetNumberOfPoints()); assert(pdPoints->GetNumberOfPoints() == pdTransPoints->GetNumberOfPoints());
for (vtkIdType i=0; i < pdPoints->GetNumberOfPoints(); i++) for (vtkIdType i = 0; i < pdPoints->GetNumberOfPoints(); i++)
{ {
double* point = pdPoints->GetPoint(i); double* point = pdPoints->GetPoint(i);
double* pointTrans = pdTransPoints->GetPoint(i); double* pointTrans = pdTransPoints->GetPoint(i);
bool isEqual = true; bool isEqual = true;
for (size_t j=0; j <3; j++) for (size_t j = 0; j < 3; j++)
{ {
if (isAngle[j]) if (isAngle[j])
{ {
isEqual &= (ArePointsWithinTolerance(point[j], pointTrans[j]) || isEqual &= (ArePointsWithinTolerance(point[j], pointTrans[j]) ||
ArePointsWithinTolerance(point[j] + static_cast<double>(twoPi), pointTrans[j]) || ArePointsWithinTolerance(point[j] + static_cast<double>(twoPi), pointTrans[j]) ||
ArePointsWithinTolerance(point[j], pointTrans[j] + static_cast<double>(twoPi))); ArePointsWithinTolerance(point[j], pointTrans[j] + static_cast<double>(twoPi)));
} }
else else
{ {
isEqual &= ArePointsWithinTolerance(point[j], pointTrans[j]); isEqual &= ArePointsWithinTolerance(point[j], pointTrans[j]);
} }
if (isEqual==false) if (isEqual == false)
{ {
std::cerr << "i=" << i << " is wrong! result value=" << pointTrans[j] << std::cerr << "i=" << i << " is wrong! result value=" << pointTrans[j]
" target value=" << point[j] <<std::endl; << " target value=" << point[j] << std::endl;
} }
} }
assert (isEqual == true); assert(isEqual == true);
} }
} }
} }
...@@ -155,7 +147,7 @@ int TestVTKMCoordinateSystemTransform(int, char*[]) ...@@ -155,7 +147,7 @@ int TestVTKMCoordinateSystemTransform(int, char*[])
MakeTestDataSet(pdCart, CoordinateType::CART); MakeTestDataSet(pdCart, CoordinateType::CART);
vtkSmartPointer<vtkmCoordinateSystemTransform> cstFilter = vtkSmartPointer<vtkmCoordinateSystemTransform> cstFilter =
vtkSmartPointer<vtkmCoordinateSystemTransform>::New(); vtkSmartPointer<vtkmCoordinateSystemTransform>::New();
{ {
cstFilter->SetInputData(pdCart); cstFilter->SetInputData(pdCart);
cstFilter->SetCartesianToCylindrical(); cstFilter->SetCartesianToCylindrical();
...@@ -168,7 +160,7 @@ int TestVTKMCoordinateSystemTransform(int, char*[]) ...@@ -168,7 +160,7 @@ int TestVTKMCoordinateSystemTransform(int, char*[])
cstFilter->SetCylindricalToCartesian(); cstFilter->SetCylindricalToCartesian();
cstFilter->Update(); cstFilter->Update();
vtkPolyData* pdCylToCar = vtkPolyData::SafeDownCast(cstFilter->GetOutput()); vtkPolyData* pdCylToCar = vtkPolyData::SafeDownCast(cstFilter->GetOutput());
ValidateCoordTransform(pdCart, pdCylToCar, {false, false, false}); ValidateCoordTransform(pdCart, pdCylToCar, { false, false, false });
} }
// Test cylindrical to cartesian // Test cylindrical to cartesian
...@@ -189,7 +181,7 @@ int TestVTKMCoordinateSystemTransform(int, char*[]) ...@@ -189,7 +181,7 @@ int TestVTKMCoordinateSystemTransform(int, char*[])
cstFilter->SetCartesianToCylindrical(); cstFilter->SetCartesianToCylindrical();
cstFilter->Update(); cstFilter->Update();
vtkPolyData* pdCarToCyl = vtkPolyData::SafeDownCast(cstFilter->GetOutput()); vtkPolyData* pdCarToCyl = vtkPolyData::SafeDownCast(cstFilter->GetOutput());
ValidateCoordTransform(pdCyl, pdCarToCyl, {true, true, false}); ValidateCoordTransform(pdCyl, pdCarToCyl, { true, true, false });
} }
// Test cartesian to spherical // Test cartesian to spherical
...@@ -205,7 +197,7 @@ int TestVTKMCoordinateSystemTransform(int, char*[]) ...@@ -205,7 +197,7 @@ int TestVTKMCoordinateSystemTransform(int, char*[])
cstFilter->SetSphericalToCartesian(); cstFilter->SetSphericalToCartesian();
cstFilter->Update(); cstFilter->Update();
vtkPolyData* pdSphToCar = vtkPolyData::SafeDownCast(cstFilter->GetOutput()); vtkPolyData* pdSphToCar = vtkPolyData::SafeDownCast(cstFilter->GetOutput());
ValidateCoordTransform(pdCart, pdSphToCar, {false, false, false}); ValidateCoordTransform(pdCart, pdSphToCar, { false, false, false });
} }
// Test spherical to cartesian // Test spherical to cartesian
...@@ -217,7 +209,7 @@ int TestVTKMCoordinateSystemTransform(int, char*[]) ...@@ -217,7 +209,7 @@ int TestVTKMCoordinateSystemTransform(int, char*[])
cstFilter->SetInputData(pdSph); cstFilter->SetInputData(pdSph);
cstFilter->SetSphericalToCartesian(); cstFilter->SetSphericalToCartesian();
cstFilter->Update(); cstFilter->Update();
vtkPolyData* pdSphToCar = vtkPolyData::SafeDownCast(cstFilter->GetOutput()); vtkPolyData* pdSphToCar = vtkPolyData::SafeDownCast(cstFilter->GetOutput());
vtkSmartPointer<vtkPolyData> pdSphToCarCopy = vtkSmartPointer<vtkPolyData>::New(); vtkSmartPointer<vtkPolyData> pdSphToCarCopy = vtkSmartPointer<vtkPolyData>::New();
pdSphToCarCopy->ShallowCopy(pdSphToCar); pdSphToCarCopy->ShallowCopy(pdSphToCar);
...@@ -225,7 +217,7 @@ int TestVTKMCoordinateSystemTransform(int, char*[]) ...@@ -225,7 +217,7 @@ int TestVTKMCoordinateSystemTransform(int, char*[])
cstFilter->SetCartesianToSpherical(); cstFilter->SetCartesianToSpherical();
cstFilter->Update(); cstFilter->Update();
vtkPolyData* pdCarToSph = vtkPolyData::SafeDownCast(cstFilter->GetOutput()); vtkPolyData* pdCarToSph = vtkPolyData::SafeDownCast(cstFilter->GetOutput());
ValidateCoordTransform(pdSph, pdCarToSph, {false, true, true}); ValidateCoordTransform(pdSph, pdCarToSph, { false, true, true });
} }
return 0; return 0;
} }
...@@ -15,7 +15,8 @@ class TestError ...@@ -15,7 +15,8 @@ class TestError
{ {
public: public:
TestError(const std::string& message, int line) TestError(const std::string& message, int line)
: Message(message), Line(line) : Message(message)
, Line(line)
{ {
} }
...@@ -31,7 +32,9 @@ private: ...@@ -31,7 +32,9 @@ private:
#define RAISE_TEST_ERROR(msg) throw TestError((msg), __LINE__) #define RAISE_TEST_ERROR(msg) throw TestError((msg), __LINE__)
#define TEST_VERIFY(cond, msg) if (!(cond)) RAISE_TEST_ERROR((msg)) #define TEST_VERIFY(cond, msg) \
if (!(cond)) \
RAISE_TEST_ERROR((msg))
inline bool IsEqualFloat(double a, double b, double e = 1e-6f) inline bool IsEqualFloat(double a, double b, double e = 1e-6f)
{ {
...@@ -53,9 +56,9 @@ void TestWithArrayHandle(const ArrayHandleType& vtkmArray) ...@@ -53,9 +56,9 @@ void TestWithArrayHandle(const ArrayHandleType& vtkmArray)
int numberOfComponents = vtkArray->GetNumberOfComponents(); int numberOfComponents = vtkArray->GetNumberOfComponents();
std::cout << "Number of components: " << numberOfComponents << "\n"; std::cout << "Number of components: " << numberOfComponents << "\n";
TEST_VERIFY( TEST_VERIFY(numberOfComponents ==
numberOfComponents == internal::FlattenVec<typename ArrayHandleType::ValueType>::GetNumberOfComponents(
internal::FlattenVec<typename ArrayHandleType::ValueType>::GetNumberOfComponents(vtkmPortal.Get(0)), vtkmPortal.Get(0)),
"Number of components don't match"); "Number of components don't match");
for (vtkIdType i = 0; i < length; ++i) for (vtkIdType i = 0; i < length; ++i)
...@@ -66,9 +69,9 @@ void TestWithArrayHandle(const ArrayHandleType& vtkmArray) ...@@ -66,9 +69,9 @@ void TestWithArrayHandle(const ArrayHandleType& vtkmArray)
for (int j = 0; j < numberOfComponents; ++j) for (int j = 0; j < numberOfComponents; ++j)
{ {
auto comp = internal::FlattenVec<typename ArrayHandleType::ValueType>::GetComponent(val, j); auto comp = internal::FlattenVec<typename ArrayHandleType::ValueType>::GetComponent(val, j);
TEST_VERIFY (IsEqualFloat(tuple[j], static_cast<double>(comp)), "values don't match"); TEST_VERIFY(IsEqualFloat(tuple[j], static_cast<double>(comp)), "values don't match");
TEST_VERIFY (IsEqualFloat(vtkArray->GetComponent(i, j), static_cast<double>(comp)), TEST_VERIFY(IsEqualFloat(vtkArray->GetComponent(i, j), static_cast<double>(comp)),
"values don't match"); "values don't match");
} }
} }
} }
...@@ -86,11 +89,12 @@ try ...@@ -86,11 +89,12 @@ try
std::cout << "Passed\n"; std::cout << "Passed\n";
std::cout << "Testing with ArrayHandleConstant\n"; std::cout << "Testing with ArrayHandleConstant\n";
TestWithArrayHandle(vtkm::cont::make_ArrayHandleConstant(vtkm::Vec<vtkm::Vec<float, 3>, 3>{{1.0f, 2.0f, 3.0f}}, 10)); TestWithArrayHandle(vtkm::cont::make_ArrayHandleConstant(
vtkm::Vec<vtkm::Vec<float, 3>, 3>{ { 1.0f, 2.0f, 3.0f } }, 10));
std::cout << "Passed\n"; std::cout << "Passed\n";
std::cout << "Testing with ArrayHandleUniformPointCoordinates\n"; std::cout << "Testing with ArrayHandleUniformPointCoordinates\n";
TestWithArrayHandle(vtkm::cont::ArrayHandleUniformPointCoordinates(vtkm::Id3{3})); TestWithArrayHandle(vtkm::cont::ArrayHandleUniformPointCoordinates(vtkm::Id3{ 3 }));
std::cout << "Passed\n"; std::cout << "Passed\n";
return EXIT_SUCCESS; return EXIT_SUCCESS;
......
...@@ -32,7 +32,8 @@ class TestError ...@@ -32,7 +32,8 @@ class TestError
{ {
public: public:
TestError(const std::string& message, int line) TestError(const std::string& message, int line)
: Message(message), Line(line) : Message(message)
, Line(line)
{ {
} }
...@@ -48,7 +49,9 @@ private: ...@@ -48,7 +49,9 @@ private:
#define RAISE_TEST_ERROR(msg) throw TestError((msg), __LINE__) #define RAISE_TEST_ERROR(msg) throw TestError((msg), __LINE__)
#define TEST_VERIFY(cond, msg) if (!(cond)) RAISE_TEST_ERROR((msg)) #define TEST_VERIFY(cond, msg) \
if (!(cond)) \
RAISE_TEST_ERROR((msg))
inline bool IsEqualFloat(double a, double b, double e = 1e-6f) inline bool IsEqualFloat(double a, double b, double e = 1e-6f)
{ {
...@@ -68,14 +71,12 @@ inline void TestEqualCells(vtkCell* c1, vtkCell* c2) ...@@ -68,14 +71,12 @@ inline void TestEqualCells(vtkCell* c1, vtkCell* c2)
inline void TestEqualVtkArrays(vtkAbstractArray* a1, vtkAbstractArray* a2) inline void TestEqualVtkArrays(vtkAbstractArray* a1, vtkAbstractArray* a2)
{ {
TEST_VERIFY(std::string(a1->GetName()) == std::string(a2->GetName()), TEST_VERIFY(std::string(a1->GetName()) == std::string(a2->GetName()), "Array names don't match");
"Array names don't match"); TEST_VERIFY(a1->GetDataType() == a2->GetDataType(), "Array data-types don't match");
TEST_VERIFY(a1->GetDataType() == a2->GetDataType(), TEST_VERIFY(
"Array data-types don't match"); a1->GetNumberOfTuples() == a2->GetNumberOfTuples(), "Array number of tuples don't match");
TEST_VERIFY(a1->GetNumberOfTuples() == a2->GetNumberOfTuples(),
"Array number of tuples don't match");
TEST_VERIFY(a1->GetNumberOfComponents() == a2->GetNumberOfComponents(), TEST_VERIFY(a1->GetNumberOfComponents() == a2->GetNumberOfComponents(),
"Array number of components don't match"); "Array number of components don't match");
auto da1 = vtkDataArray::SafeDownCast(a1); auto da1 = vtkDataArray::SafeDownCast(a1);
auto da2 = vtkDataArray::SafeDownCast(a2); auto da2 = vtkDataArray::SafeDownCast(a2);
...@@ -86,23 +87,23 @@ inline void TestEqualVtkArrays(vtkAbstractArray* a1, vtkAbstractArray* a2) ...@@ -86,23 +87,23 @@ inline void TestEqualVtkArrays(vtkAbstractArray* a1, vtkAbstractArray* a2)
da1->GetRange(range1, i); da1->GetRange(range1, i);
da2->GetRange(range2, i); da2->GetRange(range2, i);
TEST_VERIFY(IsEqualFloat(range1[0], range2[0]) && IsEqualFloat(range1[1], range2[1]), TEST_VERIFY(IsEqualFloat(range1[0], range2[0]) && IsEqualFloat(range1[1], range2[1]),
"Array ranges don't match"); "Array ranges don't match");
} }
} }
void TestDataSets(vtkDataSet* dsVtk, vtkDataSet* dsVtkm) void TestDataSets(vtkDataSet* dsVtk, vtkDataSet* dsVtkm)
{