------------------------------------------------------------------------------
| 1100 | |
| 1101 | //------------------------------------------------------------------------------ |
| 1102 | bool vtkAxisAlignedTransformFilter::Dispatch( |
| 1103 | vtkDataObject* inputDataObject, vtkDataObject* outputDataObject) |
| 1104 | { |
| 1105 | |
| 1106 | if (vtkUnstructuredGrid::SafeDownCast(inputDataObject) || |
| 1107 | vtkExplicitStructuredGrid::SafeDownCast(inputDataObject) || |
| 1108 | vtkStructuredGrid::SafeDownCast(inputDataObject) || vtkPolyData::SafeDownCast(inputDataObject)) |
| 1109 | { |
| 1110 | return this->ProcessGeneric(inputDataObject, outputDataObject); |
| 1111 | } |
| 1112 | else |
| 1113 | { |
| 1114 | int rotationMatrix[3][3]; |
| 1115 | this->GetRotationMatrix(RotationAxis, RotationAngle, rotationMatrix); |
| 1116 | |
| 1117 | if (auto imgData = vtkImageData::SafeDownCast(inputDataObject)) |
| 1118 | { |
| 1119 | auto output = vtkImageData::SafeDownCast(outputDataObject); |
| 1120 | return this->ProcessImageData(imgData, output, rotationMatrix); |
| 1121 | } |
| 1122 | else if (auto rg = vtkRectilinearGrid::SafeDownCast(inputDataObject)) |
| 1123 | { |
| 1124 | auto output = vtkRectilinearGrid::SafeDownCast(outputDataObject); |
| 1125 | return this->ProcessRectilinearGrid(rg, output, rotationMatrix); |
| 1126 | } |
| 1127 | else if (auto htg = vtkHyperTreeGrid::SafeDownCast(inputDataObject)) |
| 1128 | { |
| 1129 | auto output = vtkHyperTreeGrid::SafeDownCast(outputDataObject); |
| 1130 | return this->ProcessHTG(htg, output, rotationMatrix); |
| 1131 | } |
| 1132 | else |
| 1133 | { |
| 1134 | vtkErrorMacro("AxisAlignedTransform: Unhandled type of DataSet (" |
| 1135 | << inputDataObject->GetClassName() << ")"); |
| 1136 | return false; |
| 1137 | } |
| 1138 | } |
| 1139 | } |
| 1140 | |
| 1141 | VTK_ABI_NAMESPACE_END |
no test coverage detected