diff --git a/moveit_ros/visualization/planning_scene_rviz_plugin/src/planning_scene_display.cpp b/moveit_ros/visualization/planning_scene_rviz_plugin/src/planning_scene_display.cpp index 00d84685a5..859d0c0b48 100644 --- a/moveit_ros/visualization/planning_scene_rviz_plugin/src/planning_scene_display.cpp +++ b/moveit_ros/visualization/planning_scene_rviz_plugin/src/planning_scene_display.cpp @@ -356,10 +356,10 @@ void PlanningSceneDisplay::changedSceneName() void PlanningSceneDisplay::renderPlanningScene() { QColor color = scene_color_property_->getColor(); - Ogre::ColourValue env_color(color.redF(), color.greenF(), color.blueF()); + Ogre::ColourValue env_color(color.redF(), color.greenF(), color.blueF(), scene_alpha_property_->getFloat()); if (attached_body_color_property_) color = attached_body_color_property_->getColor(); - Ogre::ColourValue attached_color(color.redF(), color.greenF(), color.blueF()); + Ogre::ColourValue attached_color(color.redF(), color.greenF(), color.blueF(), robot_alpha_property_->getFloat()); try { diff --git a/moveit_ros/visualization/rviz_plugin_render_tools/src/planning_scene_render.cpp b/moveit_ros/visualization/rviz_plugin_render_tools/src/planning_scene_render.cpp index d5ebca65e2..10b12aa76b 100644 --- a/moveit_ros/visualization/rviz_plugin_render_tools/src/planning_scene_render.cpp +++ b/moveit_ros/visualization/rviz_plugin_render_tools/src/planning_scene_render.cpp @@ -91,7 +91,7 @@ void PlanningSceneRender::renderPlanningScene(const planning_scene::PlanningScen color.r = default_attached_color.r; color.g = default_attached_color.g; color.b = default_attached_color.b; - color.a = 1.0f; + color.a = default_attached_color.a; planning_scene::ObjectColorMap color_map; scene->getKnownObjectColors(color_map); scene_robot_->update(moveit::core::RobotStateConstPtr(rs), color, color_map); diff --git a/moveit_ros/visualization/rviz_plugin_render_tools/src/robot_state_visualization.cpp b/moveit_ros/visualization/rviz_plugin_render_tools/src/robot_state_visualization.cpp index 25c8ca8b09..7558fa7f23 100644 --- a/moveit_ros/visualization/rviz_plugin_render_tools/src/robot_state_visualization.cpp +++ b/moveit_ros/visualization/rviz_plugin_render_tools/src/robot_state_visualization.cpp @@ -145,7 +145,7 @@ void RobotStateVisualization::updateHelper(const moveit::core::RobotStateConstPt RCLCPP_ERROR_STREAM(getLogger(), "Link " << attached_body->getAttachedLinkName() << " not found in rviz::Robot"); continue; } - Ogre::ColourValue rcolor(color.r, color.g, color.b); + Ogre::ColourValue rcolor(color.r, color.g, color.b, color.a); const EigenSTL::vector_Isometry3d& ab_t = attached_body->getShapePosesInLinkFrame(); const std::vector& ab_shapes = attached_body->getShapes(); for (std::size_t j = 0; j < ab_shapes.size(); ++j)