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

Method handleNode

IO/XML/Testing/Python/TestXMLHyperTreeGrid.py:82–96  ·  view source on GitHub ↗
(self, geoCursor, levelArray, scalarArray)

Source from the content-addressed store, hash-verified

80 return True
81
82 def handleNode(self, geoCursor, levelArray, scalarArray):
83 # Add value in fields
84 idx = geoCursor.GetGlobalNodeIndex()
85 scalarArray.InsertTuple1(idx, self.value(geoCursor))
86 levelArray.InsertTuple1(idx, geoCursor.GetLevel())
87
88 if geoCursor.IsLeaf():
89 if self.shouldRefine(geoCursor):
90 geoCursor.SubdivideLeaf()
91 self.handleNode(geoCursor, levelArray, scalarArray)
92 else:
93 for ichild in range( geoCursor.GetNumberOfChildren() ):
94 geoCursor.ToChild(ichild)
95 self.handleNode(geoCursor, levelArray, scalarArray)
96 geoCursor.ToParent()
97
98#--------------------------------
99

Callers 1

Calls 11

valueMethod · 0.95
shouldRefineMethod · 0.95
InsertTuple1Method · 0.80
rangeClass · 0.50
GetGlobalNodeIndexMethod · 0.45
GetLevelMethod · 0.45
IsLeafMethod · 0.45
SubdivideLeafMethod · 0.45
GetNumberOfChildrenMethod · 0.45
ToChildMethod · 0.45
ToParentMethod · 0.45

Tested by

no test coverage detected