Template Struct AABB

Struct Documentation

template<typename PointT>
struct AABB

Public Types

using PointType = PointT
using ScalarType = typename PointType::Scalar
using Corners = Eigen::Matrix<ScalarType, kDim, kNumCorners>

Public Functions

inline void includePoint(const PointType &point)
inline bool containsPoint(const PointType &point) const
inline PointType closestPointTo(const PointType &point) const
inline PointType furthestPointFrom(const PointType &point) const
inline PointType minOffsetTo(const PointType &point) const
inline PointType maxOffsetTo(const PointType &point) const
inline PointType minOffsetTo(const AABB &aabb) const
inline PointType maxOffsetTo(const AABB &aabb) const
template<typename GeometricEntityT>
inline ScalarType minSquaredDistanceTo(const GeometricEntityT &entity) const
template<typename GeometricEntityT>
inline ScalarType maxSquaredDistanceTo(const GeometricEntityT &entity) const
template<typename GeometricEntityT>
inline ScalarType minDistanceTo(const GeometricEntityT &entity) const
template<typename GeometricEntityT>
inline ScalarType maxDistanceTo(const GeometricEntityT &entity) const
template<int dim>
inline ScalarType width() const
inline PointType widths() const
inline Corners corner_matrix() const
inline PointType corner_point(int corner_idx) const
inline ScalarType corner_coordinate(int dim_idx, int corner_idx) const
inline std::string toString() const

Public Members

PointType min = PointType::Constant(kInitialMin)
PointType max = PointType::Constant(kInitialMax)

Public Static Attributes

static constexpr int kDim = dim_v<PointT>
static constexpr int kNumCorners = int_math::exp2(kDim)
static constexpr auto kInitialMin = std::numeric_limits<ScalarType>::max()
static constexpr auto kInitialMax = std::numeric_limits<ScalarType>::lowest()