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

Method FreeSearchStructure

Common/DataModel/vtkPointLocator.cxx:120–144  ·  view source on GitHub ↗

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

Source from the content-addressed store, hash-verified

118
119//------------------------------------------------------------------------------
120void vtkPointLocator::FreeSearchStructure()
121{
122 vtkIdList* ptIds;
123 vtkIdType i;
124
125 if (this->HashTable)
126 {
127 for (i = 0; i < this->NumberOfBuckets; i++)
128 {
129 if ((ptIds = this->HashTable[i]))
130 {
131 ptIds->Delete();
132 }
133 }
134 delete[] this->HashTable;
135 this->HashTable = nullptr;
136 }
137
138 // The hash table has been invalidated.
139 // Reset the variables calculated from the dataset to their original values defined in the
140 // constructor.
141 vtkMath::UninitializeBounds(this->Bounds);
142 this->H[0] = this->H[1] = this->H[2] = 0.0;
143 this->Divisions[0] = this->Divisions[1] = this->Divisions[2] = 50;
144}
145
146//------------------------------------------------------------------------------
147// Initialize internal performance variables

Callers 4

~vtkPointLocatorMethod · 0.95
InitializeMethod · 0.95
BuildLocatorInternalMethod · 0.95
InitPointInsertionMethod · 0.95

Calls 2

UninitializeBoundsFunction · 0.85
DeleteMethod · 0.65

Tested by

no test coverage detected