From dbcfbc14c08d652f851882236a50d7297c00c5e1 Mon Sep 17 00:00:00 2001 From: "k.koide" Date: Wed, 26 Jun 2024 19:47:34 +0900 Subject: [PATCH] add setters --- include/gtsam_points/ann/flat_container.hpp | 3 +++ include/gtsam_points/ann/incremental_covariance_container.hpp | 3 +++ 2 files changed, 6 insertions(+) diff --git a/include/gtsam_points/ann/flat_container.hpp b/include/gtsam_points/ann/flat_container.hpp index 5748b4a2..422179ee 100644 --- a/include/gtsam_points/ann/flat_container.hpp +++ b/include/gtsam_points/ann/flat_container.hpp @@ -16,6 +16,9 @@ struct FlatContainer { public: /// @brief FlatContainer setting. struct Setting { + void set_min_dist_in_cell(double dist) { this->min_sq_dist_in_cell = dist * dist; } + void set_max_num_points_in_cell(size_t num_points) { this->max_num_points_in_cell = num_points; } + double min_sq_dist_in_cell = 0.1 * 0.1; ///< Minimum squared distance between points in a cell. size_t max_num_points_in_cell = 20; ///< Maximum number of points in a cell. }; diff --git a/include/gtsam_points/ann/incremental_covariance_container.hpp b/include/gtsam_points/ann/incremental_covariance_container.hpp index 4dfc333f..d068872a 100644 --- a/include/gtsam_points/ann/incremental_covariance_container.hpp +++ b/include/gtsam_points/ann/incremental_covariance_container.hpp @@ -12,6 +12,9 @@ struct IncrementalCovarianceContainer { public: /// @brief FlatContainer setting. struct Setting { + void set_min_dist_in_cell(double dist) { this->min_sq_dist_in_cell = dist * dist; } + void set_max_num_points_in_cell(size_t num_points) { this->max_num_points_in_cell = num_points; } + double min_sq_dist_in_cell = 0.1 * 0.1; ///< Minimum squared distance between points in a cell. size_t max_num_points_in_cell = 20; ///< Maximum number of points in a cell. };