17 #ifndef CARTOGRAPHER_MAPPING_2D_GRID_2D_H_ 18 #define CARTOGRAPHER_MAPPING_2D_GRID_2D_H_ 24 #include "cartographer/mapping/proto/2d/grid_2d.pb.h" 25 #include "cartographer/mapping/proto/2d/submaps_options_2d.pb.h" 26 #include "cartographer/mapping/proto/submap_visualization.pb.h" 32 common::LuaParameterDictionary*
const parameter_dictionary);
37 float max_correspondence_cost);
38 explicit Grid2D(
const proto::Grid2D& proto);
55 bool IsKnown(
const Eigen::Array2i& cell_index)
const;
65 virtual void GrowLimits(
const Eigen::Vector2f& point);
69 virtual proto::Grid2D
ToProto()
const;
72 proto::SubmapQuery::Response::SubmapTexture*
const texture,
91 int ToFlatIndex(
const Eigen::Array2i& cell_index)
const;
107 #endif // CARTOGRAPHER_MAPPING_2D_GRID_2D_H_ float GetMinCorrespondenceCost() const
virtual void GrowLimits(const Eigen::Vector2f &point)
Grid2D(const MapLimits &limits, float min_correspondence_cost, float max_correspondence_cost)
float GetMaxCorrespondenceCost() const
float max_correspondence_cost_
virtual bool DrawToSubmapTexture(proto::SubmapQuery::Response::SubmapTexture *const texture, transform::Rigid3d local_pose) const =0
Eigen::AlignedBox2i * mutable_known_cells_box()
virtual std::unique_ptr< Grid2D > ComputeCroppedGrid() const =0
virtual proto::Grid2D ToProto() const
Eigen::AlignedBox2i known_cells_box_
const Eigen::AlignedBox2i & known_cells_box() const
std::vector< uint16 > * mutable_correspondence_cost_cells()
const std::vector< uint16 > & correspondence_cost_cells() const
void ComputeCroppedLimits(Eigen::Array2i *const offset, CellLimits *const limits) const
float GetCorrespondenceCost(const Eigen::Array2i &cell_index) const
bool IsKnown(const Eigen::Array2i &cell_index) const
const std::vector< int > & update_indices() const
float min_correspondence_cost_
const MapLimits & limits() const
int ToFlatIndex(const Eigen::Array2i &cell_index) const
std::vector< uint16 > correspondence_cost_cells_
std::vector< int > * mutable_update_indices()
std::vector< int > update_indices_
proto::GridOptions2D CreateGridOptions2D(common::LuaParameterDictionary *const parameter_dictionary)