From 60b8d19cadc9b32abf0d19faca10803cbd608363 Mon Sep 17 00:00:00 2001 From: Robert Haschke Date: Sun, 7 Nov 2021 21:25:07 +0100 Subject: [PATCH] fixup! Adapt to API changes in srdfdom --- .../moveit/collision_detection/test_collision_common_panda.h | 2 +- .../test/test_bullet_continuous_collision_checking.cpp | 2 +- moveit_core/planning_scene/src/planning_scene.cpp | 2 +- moveit_setup_assistant/src/tools/moveit_config_data.cpp | 2 +- .../src/widgets/default_collisions_widget.cpp | 1 + 5 files changed, 5 insertions(+), 4 deletions(-) diff --git a/moveit_core/collision_detection/include/moveit/collision_detection/test_collision_common_panda.h b/moveit_core/collision_detection/include/moveit/collision_detection/test_collision_common_panda.h index b2ac9e9b750..fa8da15ada9 100644 --- a/moveit_core/collision_detection/include/moveit/collision_detection/test_collision_common_panda.h +++ b/moveit_core/collision_detection/include/moveit/collision_detection/test_collision_common_panda.h @@ -85,7 +85,7 @@ class CollisionDetectorPandaTest : public testing::Test acm_->setDefaultEntry(name, collision_detection::AllowedCollision::NEVER); // allow collisions for pairs that have been disabled for (auto const& collision : robot_model_->getSRDF()->getCollisionPairs()) - acm_->setEntry(collision.link1_, collision.link2_, collision.disabled); + acm_->setEntry(collision.link1_, collision.link2_, collision.disabled_); cenv_ = value_->allocateEnv(robot_model_); diff --git a/moveit_core/collision_detection_bullet/test/test_bullet_continuous_collision_checking.cpp b/moveit_core/collision_detection_bullet/test/test_bullet_continuous_collision_checking.cpp index 437423f1ca0..823c1bb8396 100644 --- a/moveit_core/collision_detection_bullet/test/test_bullet_continuous_collision_checking.cpp +++ b/moveit_core/collision_detection_bullet/test/test_bullet_continuous_collision_checking.cpp @@ -83,7 +83,7 @@ class BulletCollisionDetectionTester : public testing::Test acm_->setDefaultEntry(name, collision_detection::AllowedCollision::NEVER); // allow collisions for pairs that have been disabled for (auto const& collision : robot_model_->getSRDF()->getCollisionPairs()) - acm_->setEntry(collision.link1_, collision.link2_, collision.disabled); + acm_->setEntry(collision.link1_, collision.link2_, collision.disabled_); cenv_ = std::make_shared(robot_model_); diff --git a/moveit_core/planning_scene/src/planning_scene.cpp b/moveit_core/planning_scene/src/planning_scene.cpp index 21c9024f909..607a76eeac0 100644 --- a/moveit_core/planning_scene/src/planning_scene.cpp +++ b/moveit_core/planning_scene/src/planning_scene.cpp @@ -158,7 +158,7 @@ void PlanningScene::initialize() acm_->setDefaultEntry(name, collision_detection::AllowedCollision::ALWAYS); // allow collisions for pairs that have been disabled for (auto const& collision : getRobotModel()->getSRDF()->getCollisionPairs()) - acm_->setEntry(collision.link1_, collision.link2_, collision.disabled); + acm_->setEntry(collision.link1_, collision.link2_, collision.disabled_); setActiveCollisionDetector(collision_detection::CollisionDetectorAllocatorFCL::create()); } diff --git a/moveit_setup_assistant/src/tools/moveit_config_data.cpp b/moveit_setup_assistant/src/tools/moveit_config_data.cpp index b71aba27012..084ecabbdea 100644 --- a/moveit_setup_assistant/src/tools/moveit_config_data.cpp +++ b/moveit_setup_assistant/src/tools/moveit_config_data.cpp @@ -146,7 +146,7 @@ void MoveItConfigData::loadAllowedCollisionMatrix() // Update the allowed collision matrix, in case there has been a change for (const auto& collision : srdf_->collision_pairs_) { - allowed_collision_matrix_.setEntry(collision.link1_, collision.link2_, collision.disabled); + allowed_collision_matrix_.setEntry(collision.link1_, collision.link2_, collision.disabled_); } } diff --git a/moveit_setup_assistant/src/widgets/default_collisions_widget.cpp b/moveit_setup_assistant/src/widgets/default_collisions_widget.cpp index feb11801aa5..617dd3ee0a0 100644 --- a/moveit_setup_assistant/src/widgets/default_collisions_widget.cpp +++ b/moveit_setup_assistant/src/widgets/default_collisions_widget.cpp @@ -691,6 +691,7 @@ void DefaultCollisionsWidget::linkPairsToSRDF() dc.link1_ = pair_it->first.first; dc.link2_ = pair_it->first.second; dc.reason_ = moveit_setup_assistant::disabledReasonToString(pair_it->second.reason); + dc.disabled_ = pair_it->second.disable_check; config_data_->srdf_->collision_pairs_.push_back(dc); } }