45 CostmapModel::CostmapModel(
const Costmap2D& ma) : costmap_(ma) {}
48 double inscribed_radius,
double circumscribed_radius){
56 unsigned int cell_x, cell_y;
63 if(footprint.size() < 3){
65 if(cost == NO_INFORMATION)
67 if(cost == LETHAL_OBSTACLE || cost == INSCRIBED_INFLATED_OBSTACLE)
73 unsigned int x0, x1, y0, y1;
74 double line_cost = 0.0;
75 double footprint_cost = 0.0;
78 for(
unsigned int i = 0; i < footprint.size() - 1; ++i){
87 line_cost =
lineCost(x0, x1, y0, y1);
88 footprint_cost = std::max(line_cost, footprint_cost);
104 line_cost =
lineCost(x0, x1, y0, y1);
105 footprint_cost = std::max(line_cost, footprint_cost);
111 return footprint_cost;
117 double line_cost = 0.0;
118 double point_cost = -1.0;
122 point_cost =
pointCost( line.getX(), line.getY() );
127 if(line_cost < point_cost)
128 line_cost = point_cost;
137 if(cost == NO_INFORMATION)
139 if(cost == LETHAL_OBSTACLE)