13#ifndef EBGeometry_BoundingVolumes_H
14#define EBGeometry_BoundingVolumes_H
45 os <<
'(' <<
sphere.getCentroid() <<
", " <<
sphere.getRadius() <<
')';
225 os <<
'(' <<
aabb.getLowCorner() <<
", " <<
aabb.getHighCorner() <<
')';
407#include "EBGeometry_NamespaceFooter.hpp"
409#include "EBGeometry_BoundingVolumesImplem.hpp"
Declaration of 2D and 3D point/vector classes with templated precision. Used with DCEL tools.
Axis-aligned bounding box as bounding volume.
Definition EBGeometry_BoundingVolumes.hpp:217
AABBT() noexcept
Default constructor (does nothing)
Class which encloses a set of points using a bounding sphere.
Definition EBGeometry_BoundingVolumes.hpp:37
T getDistance(const Vec3 &a_x0) const noexcept
Get the distance to this bounding sphere (points inside the sphere have a zero distance)
friend std::ostream & operator<<(std::ostream &os, const BoundingSphereT< T > &sphere)
For outputting a vector to an output stream.
Definition EBGeometry_BoundingVolumes.hpp:43
T getArea() const noexcept
Get the sphere area.
T getVolume() const noexcept
Get the sphere volume.
T getOverlappingVolume(const BoundingSphereT< T > &a_other) const noexcept
Compute the overlapping volume between this bounding sphere and another.
T & getRadius() noexcept
Get modifiable radius for this sphere.
BoundingSphereT() noexcept
Default constructor. Leaves object in undefined state.
bool intersects(const BoundingSphereT &a_other) const noexcept
Check if this bounding sphere intersect another bounding sphere.
void define(const std::vector< Vec3T< P > > &a_points, const BoundingVolumeAlgorithm &a_alg) noexcept
Template define function which takes a set of 3D points (mixed precision allowed).
void buildRitter(const std::vector< Vec3T< P > > &a_points) noexcept
Template function which computes the bounding sphere for a set of points (mixed precision allowed) us...
Vec3 m_center
Sphere center.
Definition EBGeometry_BoundingVolumes.hpp:198
Vec3 & getCentroid() noexcept
Get modifiable center for this sphere.
T m_radius
Sphere radius.
Definition EBGeometry_BoundingVolumes.hpp:193
BoundingVolumeAlgorithm
Typename for possible algorithms that support the computation of a bounding sphere for a set of 3D po...
Definition EBGeometry_BoundingVolumes.hpp:55
Three-dimensional vector class with arithmetic operators.
Definition EBGeometry_Vec.hpp:218
Namespace for encapsulating various bounding volumes for usage with BVHs.
Definition EBGeometry_BoundingVolumes.hpp:28