5#ifndef SAPPHIRE_MATHS_AABB3D_GUARD
6#define SAPPHIRE_MATHS_AABB3D_GUARD
88 constexpr
bool Equals(const
AABB3D& _other, T _epsilon = std::numeric_limits<T>::epsilon()) const noexcept;
98 constexpr
bool operator==(const
AABB3D& _rhs) const noexcept;
107 constexpr
bool operator!=(const
AABB3D& _rhs) const noexcept;
219 template <
typename T>
220 std::string ToString(
const AABB3D<T>& _aabb);
240#include <SA/Maths/Geometry/AABB3D.inl>
Vector 3 type implementation.
AABB 2D Sapphire's class.
Definition AABB2D.hpp:32
AABB 3D Sapphire's class.
Definition AABB3D.hpp:31
bool IsColliding(const AABB3D &_other) const
Perform collision test on every axis.
float Depth() const
Compute depth (Z axis) from min and max.
constexpr bool Equals(const AABB3D &_other, T _epsilon=std::numeric_limits< T >::epsilon()) const noexcept
Compare 2 AABB3D.
Vec3< T > max
Max box component.
Definition AABB3D.hpp:36
bool IsCollidingX(const AABB3D &_other) const
Perform collision test on X axis only.
Vec3< T > Center() const
Compute center from min and max.
AABB3D(const AABB3D &_first, const AABB3D &_second)
Merge 2 AABB box.
Vec3< T > min
Min box component.
Definition AABB3D.hpp:33
bool IsCollidingY(const AABB3D &_other) const
Perform collision test on Y axis only.
float Area() const
Compute area from min and max.
bool IsCollidingZ(const AABB3D &_other) const
Perform collision test on Z axis only.
AABB3D()=default
Default constructor.
AABB3D(const Vec3< T > &_min, const Vec3< T > &_max)
Value constructor from min and max.
float Width() const
Compute width (X axis) from min and max.
static AABB3D Merge(const AABB3D &_first, const AABB3D &_second)
Merge 2 AABB3D box to create a big AABB3D which wrap both boxes.
AABB3D(const AABB2D< T > &_aabb2D) noexcept
Constructor from AABB2D.
float Height() const
Compute height (Y axis) from min and max.
bool IsValid() const noexcept
Wether this AABB has valid values (ie min < max);.
Vector 3 Sapphire-Maths class.
Definition Vector3.hpp:43