| 126 | //------------------------------------------------------------------------------ |
| 127 | template <typename GridType> |
| 128 | void ApplyScale(GridType* grid, double Scale[3]) |
| 129 | { |
| 130 | vtkDoubleArray* xCoordinate = vtkDoubleArray::SafeDownCast(grid->GetXCoordinates()); |
| 131 | for (vtkIdType i = 0; i < xCoordinate->GetNumberOfTuples(); ++i) |
| 132 | { |
| 133 | xCoordinate->SetTuple1(i, xCoordinate->GetTuple1(i) * Scale[0]); |
| 134 | } |
| 135 | vtkDoubleArray* yCoordinate = vtkDoubleArray::SafeDownCast(grid->GetYCoordinates()); |
| 136 | for (vtkIdType i = 0; i < yCoordinate->GetNumberOfTuples(); ++i) |
| 137 | { |
| 138 | yCoordinate->SetTuple1(i, yCoordinate->GetTuple1(i) * Scale[1]); |
| 139 | } |
| 140 | vtkDoubleArray* zCoordinate = vtkDoubleArray::SafeDownCast(grid->GetZCoordinates()); |
| 141 | for (vtkIdType i = 0; i < zCoordinate->GetNumberOfTuples(); ++i) |
| 142 | { |
| 143 | zCoordinate->SetTuple1(i, zCoordinate->GetTuple1(i) * Scale[2]); |
| 144 | } |
| 145 | } |
| 146 | |
| 147 | //------------------------------------------------------------------------------ |
| 148 | int HashLut(int rotationAxis, int normalAxis, int angle) |
no test coverage detected