------------------------------------------------------------------------------ Fast implementation of GetCellBounds(). Bounds are calculated without constructing a cell. This method is expected to be thread-safe.
| 279 | // Fast implementation of GetCellBounds(). Bounds are calculated without |
| 280 | // constructing a cell. This method is expected to be thread-safe. |
| 281 | void vtkPolyData::GetCellBounds(vtkIdType cellId, double bounds[6]) |
| 282 | { |
| 283 | if (!this->Cells) |
| 284 | { |
| 285 | this->BuildCells(); |
| 286 | } |
| 287 | |
| 288 | const TaggedCellId tag = this->Cells->GetTag(cellId); |
| 289 | if (tag.IsDeleted()) |
| 290 | { |
| 291 | std::fill_n(bounds, 6, 0.); |
| 292 | return; |
| 293 | } |
| 294 | |
| 295 | vtkCellArray* cells = this->GetCellArrayInternal(tag); |
| 296 | const vtkIdType localCellId = tag.GetCellId(); |
| 297 | cells->Dispatch(ComputeCellBoundsVisitor{}, this->Points, localCellId, bounds); |
| 298 | } |
| 299 | |
| 300 | //------------------------------------------------------------------------------ |
| 301 | // This method only considers points that are used by one or more cells. Thus |
nothing calls this directly
no test coverage detected