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

Function GetGrid

Examples/AMR/Cxx/AMRCommon.h:113–121  ·  view source on GitHub ↗

------------------------------------------------------------------------------ Constructs a uniform grid instance given the prescribed origin, grid spacing and dimensions.

Source from the content-addressed store, hash-verified

111// Constructs a uniform grid instance given the prescribed
112// origin, grid spacing and dimensions.
113vtkUniformGrid* GetGrid(double* origin, double* h, int* ndim)
114{
115 vtkNew<vtkUniformGrid> grd;
116 grd->Initialize();
117 grd->SetOrigin(origin);
118 grd->SetSpacing(h);
119 grd->SetDimensions(ndim);
120 return grd;
121}
122
123//------------------------------------------------------------------------------
124// Computes the cell center for the cell corresponding to cellIdx w.r.t.

Callers 2

GetAMRDataSetFunction · 0.70
GetAMRDataSetFunction · 0.70

Calls 4

InitializeMethod · 0.45
SetOriginMethod · 0.45
SetSpacingMethod · 0.45
SetDimensionsMethod · 0.45

Tested by

no test coverage detected