Skip to content

Commit

Permalink
Merge pull request #54 from PickNikRobotics/pr-fix-joint-ordering
Browse files Browse the repository at this point in the history
Switch from `std::set` to `std::vector` to prevent joint name alphabetization
  • Loading branch information
Robotawi authored Jun 26, 2023
2 parents c9e050a + 631915d commit 9904c89
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/robot.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -99,11 +99,11 @@ auto get_active_variable_indices(std::shared_ptr<moveit::core::RobotModel const>
// For each of the active joints in the joint model group
// If those are in the ones we are using and the joint is not a mimic
// Then get all the variable names from the joint moodel
auto active_variable_names = std::set<std::string>{};
auto active_variable_names = std::vector<std::string>{};
for (auto const* joint_model : jmg->getActiveJointModels()) {
if (joint_usage[joint_model->getJointIndex()] && !joint_model->getMimic()) {
for (auto& name : joint_model->getVariableNames()) {
active_variable_names.insert(name);
active_variable_names.push_back(name);
}
}
}
Expand Down

0 comments on commit 9904c89

Please # to comment.