From 4a2b7602a3df643cf842093dab081f1e0a7a3dd3 Mon Sep 17 00:00:00 2001 From: Marc Morcos <30278842+Marc-Morcos@users.noreply.github.com> Date: Mon, 19 Aug 2024 14:16:09 -0400 Subject: [PATCH] Fix polygons not clearing (#72) * Add behavior tree to navigate to start before starting fields navigation * snake case * comments * rviz visualization for demo * Update rviz_config.rviz * Linting and add to other demo * Fix polygons not clearing, credit to tonynajjar --------- Co-authored-by: Marc Morcos <30278842+MarcM0@users.noreply.github.com> --- opennav_coverage_bt/src/compute_complete_coverage_path.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/opennav_coverage_bt/src/compute_complete_coverage_path.cpp b/opennav_coverage_bt/src/compute_complete_coverage_path.cpp index 307aca1..59b7fb6 100644 --- a/opennav_coverage_bt/src/compute_complete_coverage_path.cpp +++ b/opennav_coverage_bt/src/compute_complete_coverage_path.cpp @@ -46,6 +46,7 @@ void ComputeCoveragePathAction::on_tick() // Convert from vector of Polygons to coverage sp. message std::vector polys; getInput("polygons", polys); + goal_.polygons.clear(); goal_.polygons.resize(polys.size()); for (unsigned int i = 0; i != polys.size(); i++) { for (unsigned int j = 0; j != polys[i].points.size(); j++) {