diff options
author | Dan Goodliffe <dan@randomdan.homeip.net> | 2025-03-06 02:41:09 +0000 |
---|---|---|
committer | Dan Goodliffe <dan@randomdan.homeip.net> | 2025-03-11 01:13:52 +0000 |
commit | ba69d51cc372197ef55feb87a33ed03afd1b0ca3 (patch) | |
tree | ce50ac42a8d30d5246ca767107d76886d7237e69 /game/geoData.h | |
parent | Pass frustum into render functions (diff) | |
download | ilt-ba69d51cc372197ef55feb87a33ed03afd1b0ca3.tar.bz2 ilt-ba69d51cc372197ef55feb87a33ed03afd1b0ca3.tar.xz ilt-ba69d51cc372197ef55feb87a33ed03afd1b0ca3.zip |
Create AxisAlignedBoundingBox
Used to define the extents of GeoData mesh
Diffstat (limited to 'game/geoData.h')
-rw-r--r-- | game/geoData.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/game/geoData.h b/game/geoData.h index b2a75bd..a504f9b 100644 --- a/game/geoData.h +++ b/game/geoData.h @@ -2,6 +2,7 @@ #include "collections.h" // IWYU pragma: keep IterableCollection #include "geoDataMesh.h" +#include "gfx/aabb.h" #include "surface.h" #include <filesystem> #include <glm/vec2.hpp> @@ -57,10 +58,10 @@ public: std::set<FaceHandle> setHeights(std::span<const GlobalPosition3D> triangleStrip, const SetHeightsOpts &); - [[nodiscard]] auto + [[nodiscard]] auto & getExtents() const { - return std::tie(lowerExtent, upperExtent); + return extents; } template<typename HandleT> @@ -80,5 +81,5 @@ protected: virtual void afterChange(); private: - GlobalPosition3D lowerExtent {}, upperExtent {}; + AxisAlignedBoundingBox extents; }; |