From 8714c7d218d14ca8b4f80bf8e346e93c6dca8aa7 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Sun, 26 Jan 2025 12:21:59 +0200 Subject: [PATCH] Use vector and deque instead of list --- source/geometry/loader.h | 4 ++-- source/geometry/shape.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/source/geometry/loader.h b/source/geometry/loader.h index c3774b7..bcb5a90 100644 --- a/source/geometry/loader.h +++ b/source/geometry/loader.h @@ -1,7 +1,7 @@ #ifndef MSP_GEOMETRY_LOADER_H_ #define MSP_GEOMETRY_LOADER_H_ -#include +#include #include #include "extrudedshape.h" #include "halfspace.h" @@ -21,7 +21,7 @@ class DimensionIndependentLoader: public DataFile::Loader { protected: bool single = true; - std::list>> shapes; + std::vector>> shapes; DimensionIndependentLoader(bool = true); diff --git a/source/geometry/shape.h b/source/geometry/shape.h index bd90ba6..91d622b 100644 --- a/source/geometry/shape.h +++ b/source/geometry/shape.h @@ -1,7 +1,7 @@ #ifndef MSP_GEOMETRY_SHAPE_H_ #define MSP_GEOMETRY_SHAPE_H_ -#include +#include #include #include #include @@ -73,7 +73,7 @@ inline BoundingBox Shape::bisect_axis_aligned_bounding_box(unsigned throw std::invalid_argument("Shape::bisect_axis_aligned_bounding_box"); // Form the root cell from the loosest approximation of a bounding box. - std::list queue; + std::deque queue; queue.push_back(CoverageCell()); CoverageCell &root = queue.front(); root.level = 0; -- 2.45.2