23namespace localization {
31 unsigned char intensity) {
32 Eigen::Vector2d coord2d(coordinate[0], coordinate[1]);
39 map_cell.
SetValue(coordinate[2], intensity);
47 unsigned char intensity) {
48 Eigen::Vector2d coord2d(coordinate[0], coordinate[1]);
55 map_cell.
SetValue(coordinate[2], intensity);
67 unsigned char intensity) {
68 Eigen::Vector2d coord2d(coordinate[0], coordinate[1]);
76 coordinate[2], intensity,
82 std::vector<unsigned char>* values)
const {
83 Eigen::Vector2d coord2d(coordinate[0], coordinate[1]);
94 std::vector<float>* vars)
const {
95 Eigen::Vector2d coord2d(coordinate[0], coordinate[1]);
106 std::vector<float>* alts)
const {
107 Eigen::Vector2d coord2d(coordinate[0], coordinate[1]);
118 std::vector<float>* alt_vars)
const {
119 Eigen::Vector2d coord2d(coordinate[0], coordinate[1]);
130 std::vector<unsigned int>* counts)
const {
131 Eigen::Vector2d coord2d(coordinate[0], coordinate[1]);
142 const Eigen::Vector3d& coordinate)
const {
143 Eigen::Vector2d coord2d(coordinate[0], coordinate[1]);
154 Eigen::Vector2d coord2d(coordinate[0], coordinate[1]);
165 Eigen::Vector2d coord2d(coordinate[0], coordinate[1]);
176 Eigen::Vector2d coord2d(coordinate[0], coordinate[1]);
187 const Eigen::Vector3d& coordinate)
const {
188 Eigen::Vector2d coord2d(coordinate[0], coordinate[1]);
The data structure of a Node in the map.
BaseMapMatrix * map_matrix_
The data structure of the map datas, which is a matrix.
bool is_changed_
Has the map node been changed.
const BaseMapConfig * map_config_
The map settings.
bool GetCoordinate(const Eigen::Vector2d &coordinate, unsigned int *x, unsigned int *y) const
Given the global coordinate, get the local 2D coordinate of the map cell matrix.
The options of the reflectance map.
float map_layer_alt_thres_
The threshold to split more layers in the map node.
void SetValue(const Eigen::Vector3d &coordinate, unsigned char intensity)
Set the value of a pixel in the map node.
float min_altitude_
The min altitude of point cloud in the node.
void GetAlt(const Eigen::Vector3d &coordinate, std::vector< float > *alts) const
Given the 3D global coordinate, get the map cell's average altitude of each layer.
void SetValueLayer(const Eigen::Vector3d &coordinate, unsigned char intensity)
Set the value of a pixel in a layer in the map node.
bool SetValueIfInBound(const Eigen::Vector3d &coordinate, unsigned char intensity)
Set the value of a pixel in the map node if the pixel in the node.
void GetAltVar(const Eigen::Vector3d &coordinate, std::vector< float > *alt_vars) const
Given the 3D global coordinate, get the map cell's variance of the altitude of each layer.
void GetValue(const Eigen::Vector3d &coordinate, std::vector< unsigned char > *values) const
Given the 3D global coordinate, get the map cell average intensity of each layer.
void GetCount(const Eigen::Vector3d &coordinate, std::vector< unsigned int > *counts) const
Given the 3D global coordinate, get the map cell's count of the samples of each layer.
void GetVar(const Eigen::Vector3d &coordinate, std::vector< float > *vars) const
Given the 3D global coordinate, get the map cell variance of the intensity of each layer.
The multiple layers of the cell.
void GetCount(std::vector< unsigned int > *counts) const
Get the count of the samples of all layers in the map cell.
void GetVar(std::vector< float > *vars) const
Get the variance of the intensity of all layers in the map cell.
void SetValueLayer(double altitude, unsigned char intensity, double altitude_thres=10.0)
Set the value of a layer that layer_id > 0.
void GetAlt(std::vector< float > *alts) const
Get the average altitude of all layers in the map cell.
void GetAltVar(std::vector< float > *alt_vars) const
Get the variance of the altitude of all layers in the map cell.
void SetValue(double altitude, unsigned char intensity)
Set the value.
void GetValue(std::vector< unsigned char > *values) const
Load the map cell from a binary chunk.