------------------------------------------------------------------------------ Compute Length squared of cell (i.e., bounding box diagonal squared).
| 489 | //------------------------------------------------------------------------------ |
| 490 | // Compute Length squared of cell (i.e., bounding box diagonal squared). |
| 491 | double vtkCell::GetLength2() |
| 492 | { |
| 493 | double diff, l = 0.0; |
| 494 | int i; |
| 495 | |
| 496 | this->GetBounds(); |
| 497 | for (i = 0; i < 3; i++) |
| 498 | { |
| 499 | diff = this->Bounds[2 * i + 1] - this->Bounds[2 * i]; |
| 500 | l += diff * diff; |
| 501 | } |
| 502 | return l; |
| 503 | } |
| 504 | |
| 505 | //------------------------------------------------------------------------------ |
| 506 | // Return center of the cell in parametric coordinates. |