|
lmgl 1.0.0
A lightweight OpenGL graphics engine library written in C++
|
Axis-Aligned Bounding Box (AABB) structure. More...
#include <frustum.hpp>
Public Member Functions | |
| AABB () | |
| Default constructor initializing an empty AABB. | |
| AABB (const glm::vec3 &min, const glm::vec3 &max) | |
| Parameterized constructor. | |
| glm::vec3 | get_center () const |
| Get the center point of the AABB. | |
| glm::vec3 | get_extents () const |
| Get the extents of the AABB. | |
| AABB | transform (const glm::mat4 &matrix) const |
| Transform the AABB with a matrix. | |
| void | expand (const glm::vec3 &point) |
| Expand the AABB to include a point. | |
| void | merge (const AABB &other) |
| Merge the AABB with another AABB. | |
Public Attributes | |
| glm::vec3 | min |
| Minimum corner point of the AABB. | |
| glm::vec3 | max |
| Maximum corner point of the AABB. | |
Axis-Aligned Bounding Box (AABB) structure.
Represents a 3D bounding box defined by minimum and maximum corner points. Provides methods for transformations, expansion, and merging with other AABBs.
|
inline |
Default constructor initializing an empty AABB.
Initializes min and max to zero vectors.
|
inline |
Parameterized constructor.
Initializes the AABB with specified minimum and maximum corner points.
| min | Minimum corner point. |
| max | Maximum corner point. |
| void lmgl::scene::AABB::expand | ( | const glm::vec3 & | point | ) |
|
inline |
|
inline |
| void lmgl::scene::AABB::merge | ( | const AABB & | other | ) |
| AABB lmgl::scene::AABB::transform | ( | const glm::mat4 & | matrix | ) | const |