BoundingBox refactoring