From 6178f294cd6612e486f9486de8ad8e9771d675a8 Mon Sep 17 00:00:00 2001 From: ccolin Date: Sat, 19 Feb 2022 00:13:21 +0100 Subject: [PATCH] remove unnecessary implementation detail --- src/main.cc | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/main.cc b/src/main.cc index 6548301..f6c1720 100644 --- a/src/main.cc +++ b/src/main.cc @@ -14,7 +14,6 @@ #include #include #include -#include #include #include @@ -60,7 +59,7 @@ int main(int argc, char **argv) { /* Display angles in console. */ anglesFilter->Update(); vtkUnstructuredGrid *grid = anglesFilter->GetOutput(); - auto *angles = vtkDoubleArray::SafeDownCast(grid->GetCellData()->GetArray("angles")); + auto *angles = grid->GetCellData()->GetArray("angles"); for (ssize_t i = 0; i < angles->GetNumberOfTuples(); i++) { std::cout << "cell " << i << ": "; for (ssize_t j = 0; j < angles->GetNumberOfComponents(); j++) { @@ -76,7 +75,7 @@ int main(int argc, char **argv) { /* Display aspect ratios in console. */ aspectRatioFilter->Update(); grid = aspectRatioFilter->GetOutput(); - auto *aspectRatios = vtkDoubleArray::SafeDownCast(grid->GetCellData()->GetArray("aspect_ratio")); + auto *aspectRatios = grid->GetCellData()->GetArray("aspect_ratio"); for (ssize_t i = 0; i < aspectRatios->GetNumberOfTuples(); i++) { std::cout << "cell " << i << ": " << aspectRatios->GetTuple1(i) << "\n";