MCPcopy Create free account
hub / github.com/Kitware/VTK / GetDataDimension

Method GetDataDimension

Common/DataModel/vtkStructuredData.cxx:36–57  ·  view source on GitHub ↗

Return the topological dimension of the data (e.g., 0, 1, 2, or 3D).

Source from the content-addressed store, hash-verified

34
35// Return the topological dimension of the data (e.g., 0, 1, 2, or 3D).
36int 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//------------------------------------------------------------------------------
60int vtkStructuredData::GetDataDimension(int ext[6])

Callers

nothing calls this directly

Calls 1

GetDataDimensionFunction · 0.85

Tested by

no test coverage detected