------------------------------------------------------------------------------
| 373 | |
| 374 | //------------------------------------------------------------------------------ |
| 375 | void vtkUniformHyperTreeGrid::GetGridBounds(double* bounds) |
| 376 | { |
| 377 | // Recompute each call |
| 378 | // Compute bounds from uniform grid parameters |
| 379 | for (unsigned int i = 0; i < 3; ++i) |
| 380 | { |
| 381 | unsigned int di = 2 * i; |
| 382 | unsigned int dip = di + 1; |
| 383 | bounds[di] = this->Origin[i]; |
| 384 | if (this->GetDimensions()[i] == 1) |
| 385 | { |
| 386 | bounds[dip] = this->Origin[i]; |
| 387 | } |
| 388 | else |
| 389 | { |
| 390 | bounds[dip] = this->Origin[i] + this->GetCellDims()[i] * this->GridScale[i]; |
| 391 | } |
| 392 | |
| 393 | // Ensure that the bounds are increasing |
| 394 | if (bounds[di] > bounds[dip]) |
| 395 | { |
| 396 | std::swap(bounds[di], bounds[dip]); |
| 397 | } |
| 398 | } |
| 399 | } |
| 400 | |
| 401 | //------------------------------------------------------------------------------ |
| 402 | void vtkUniformHyperTreeGrid::ShallowCopy(vtkDataObject* src) |
nothing calls this directly
no test coverage detected