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

Method GetLength

Common/DataModel/vtkGenericDataSet.cxx:158–172  ·  view source on GitHub ↗

------------------------------------------------------------------------------ Description: Length of the diagonal of the bounding box.

Source from the content-addressed store, hash-verified

156// Description:
157// Length of the diagonal of the bounding box.
158double vtkGenericDataSet::GetLength()
159{
160 double result, l = 0.0;
161 int i;
162
163 this->ComputeBounds();
164 for (i = 0; i < 3; i++)
165 {
166 result = this->Bounds[2 * i + 1] - this->Bounds[2 * i];
167 l += result * result;
168 }
169 result = sqrt(l);
170 assert("post: positive_result" && result >= 0);
171 return result;
172}
173
174//------------------------------------------------------------------------------
175vtkMTimeType vtkGenericDataSet::GetMTime()

Callers

nothing calls this directly

Calls 3

sqrtFunction · 0.50
assertFunction · 0.50
ComputeBoundsMethod · 0.45

Tested by

no test coverage detected