Return the topological dimension of the data (e.g., 0, 1, 2, or 3D).
| 34 | |
| 35 | // Return the topological dimension of the data (e.g., 0, 1, 2, or 3D). |
| 36 | int vtkStructuredData::GetDataDimension(int dataDescription) |
| 37 | { |
| 38 | switch (dataDescription) |
| 39 | { |
| 40 | case VTK_STRUCTURED_EMPTY: |
| 41 | return 0; // Should I put -1? |
| 42 | case VTK_STRUCTURED_SINGLE_POINT: |
| 43 | return 0; |
| 44 | case VTK_STRUCTURED_X_LINE: |
| 45 | case VTK_STRUCTURED_Y_LINE: |
| 46 | case VTK_STRUCTURED_Z_LINE: |
| 47 | return 1; |
| 48 | case VTK_STRUCTURED_XY_PLANE: |
| 49 | case VTK_STRUCTURED_YZ_PLANE: |
| 50 | case VTK_STRUCTURED_XZ_PLANE: |
| 51 | return 2; |
| 52 | case VTK_STRUCTURED_XYZ_GRID: |
| 53 | return 3; |
| 54 | default: |
| 55 | return -1; |
| 56 | } |
| 57 | } |
| 58 | |
| 59 | //------------------------------------------------------------------------------ |
| 60 | int vtkStructuredData::GetDataDimension(int ext[6]) |
nothing calls this directly
no test coverage detected