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

Method MakeDistributedId

Common/DataModel/vtkDistributedGraphHelper.cxx:133–144  ·  view source on GitHub ↗

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

Source from the content-addressed store, hash-verified

131
132//------------------------------------------------------------------------------
133vtkIdType vtkDistributedGraphHelper::MakeDistributedId(int owner, vtkIdType local)
134{
135 int numProcs = this->Graph->GetInformation()->Get(vtkDataObject::DATA_NUMBER_OF_PIECES());
136
137 if (numProcs > 1)
138 {
139 assert(owner >= 0 && owner < numProcs);
140 return (static_cast<vtkIdType>(owner) << this->indexBits) | local;
141 }
142
143 return local;
144}
145
146//------------------------------------------------------------------------------
147void vtkDistributedGraphHelper::AttachToGraph(vtkGraph* graph)

Callers 7

SetGraphMethod · 0.80
IncrementMethod · 0.80
SetGraphMethod · 0.80
FindVertexMethod · 0.80
AddVertexInternalMethod · 0.80
vtk_edge_iteratorMethod · 0.80
verticesFunction · 0.80

Calls 3

assertFunction · 0.50
GetMethod · 0.45
GetInformationMethod · 0.45

Tested by

no test coverage detected