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

Method GetBounds

Common/DataModel/vtkOverlappingAMRMetaData.cxx:659–683  ·  view source on GitHub ↗

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

Source from the content-addressed store, hash-verified

657
658//------------------------------------------------------------------------------
659void vtkOverlappingAMRMetaData::GetBounds(unsigned int level, unsigned int id, double* bb)
660{
661 unsigned int index = this->GetAbsoluteBlockIndex(level, id);
662 if (this->HasBlockBounds(index))
663 {
664 const vtkBoundingBox& bounds = this->BlockBounds[index];
665 if (bounds.IsValid())
666 {
667 bounds.GetBounds(bb);
668 }
669 else
670 {
671 vtkErrorMacro("Could not GetBounds, please SetBounds for all blocks");
672 }
673 }
674 else if (this->HasSpacing(level))
675 {
676 const vtkAMRBox& box = this->Boxes[index];
677 vtkAMRBox::GetBounds(box, this->Origin, this->Spacing->GetTuple(level), bb);
678 }
679 else
680 {
681 vtkErrorMacro("Could not GetBounds, please set Spacing or BlockBounds");
682 }
683}
684
685//------------------------------------------------------------------------------
686const vtkAMRBox& vtkOverlappingAMRMetaData::GetAMRBox(unsigned int level, unsigned int id) const

Callers 3

FindCellMethod · 0.95
FindGridMethod · 0.95
UpdateBoundsMethod · 0.45

Calls 10

HasBlockBoundsMethod · 0.95
HasSpacingMethod · 0.95
HasValidBoundsMethod · 0.95
UpdateBoundsMethod · 0.95
GetBoundsFunction · 0.70
GetAbsoluteBlockIndexMethod · 0.45
IsValidMethod · 0.45
GetTupleMethod · 0.45
GetNumberOfLevelsMethod · 0.45
GetNumberOfBlocksMethod · 0.45

Tested by

no test coverage detected