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

Method GetEdgeOwner

Common/DataModel/vtkDistributedGraphHelper.cxx:91–115  ·  view source on GitHub ↗

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

Source from the content-addressed store, hash-verified

89
90//------------------------------------------------------------------------------
91vtkIdType vtkDistributedGraphHelper::GetEdgeOwner(vtkIdType e_id) const
92{
93 vtkIdType owner = e_id;
94 int numProcs = this->Graph->GetInformation()->Get(vtkDataObject::DATA_NUMBER_OF_PIECES());
95
96 if (numProcs > 1)
97 {
98 if (e_id & this->signBitMask)
99 {
100 owner ^= this->signBitMask; // remove sign bit
101 vtkIdType tmp = owner >> this->indexBits; // so can right-shift
102 owner = tmp | this->highBitShiftMask; // and append sign bit back
103 }
104 else
105 {
106 owner = e_id >> this->indexBits;
107 }
108 }
109 else // numProcs = 1
110 {
111 owner = 0;
112 }
113
114 return owner;
115}
116
117//------------------------------------------------------------------------------
118vtkIdType vtkDistributedGraphHelper::GetEdgeIndex(vtkIdType e_id) const

Callers 13

SetGraphMethod · 0.80
NextMethod · 0.80
GetSourceVertexMethod · 0.80
GetTargetVertexMethod · 0.80
SetEdgePointsMethod · 0.80
GetEdgePointsMethod · 0.80
GetNumberOfEdgePointsMethod · 0.80
GetEdgePointMethod · 0.80
SetEdgePointMethod · 0.80
ClearEdgePointsMethod · 0.80
AddEdgePointMethod · 0.80
vtk_edge_iteratorMethod · 0.80

Calls 2

GetMethod · 0.45
GetInformationMethod · 0.45

Tested by

no test coverage detected