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

Method GetLevelZeroOriginFromIndex

Common/DataModel/vtkHyperTreeGrid.cxx:1523–1537  ·  view source on GitHub ↗

------------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

1521
1522//------------------------------------------------------------------------------
1523void vtkHyperTreeGrid::GetLevelZeroOriginFromIndex(vtkIdType treeindex, double* Origin)
1524{
1525 assert("pre: exist_coordinates_explict" && this->WithCoordinates);
1526
1527 // Compute origin and size of the cursor
1528 unsigned int i, j, k;
1529 this->GetLevelZeroCoordinatesFromIndex(treeindex, i, j, k);
1530
1531 vtkDataArray* xCoords = this->XCoordinates;
1532 vtkDataArray* yCoords = this->YCoordinates;
1533 vtkDataArray* zCoords = this->ZCoordinates;
1534 Origin[0] = xCoords->GetTuple1(i);
1535 Origin[1] = yCoords->GetTuple1(j);
1536 Origin[2] = zCoords->GetTuple1(k);
1537}
1538
1539//------------------------------------------------------------------------------
1540vtkIdType vtkHyperTreeGrid::GetGlobalNodeIndexMax()

Callers 4

InitializeMethod · 0.45
InitializeMethod · 0.45
InitializeMethod · 0.45
InitializeMethod · 0.45

Calls 3

GetTuple1Method · 0.80
assertFunction · 0.50

Tested by

no test coverage detected