I am working on a project in ROS2 and Gazebo where I have to stream images at runtime and load them onto textures to place into the world as a robot moves around.

From ROS2 I have managed without problem to load images onto planes and position them in the world. However: Gazebo only recognizes the images if they're placed in a directory on the GAZEBO_MODEL_PATH BEFORE Gazebo is launched. If I try to add an image to models/my_plane/textures/ (for instance) while Gazebo is running, it doesn't acknowledge them until I restart Gazebo.

I am sure there must be a way to reload GAZEBO_MODEL_PATH during runtime or place files in some dynamic directory or implement some other workaround for this issue - but I haven't been able to find one yet.

Any insights, explanations, or code examples on how to use files added to GAZEBO_MODEL_PATH at runtime would be greatly appreciated. Thanks!

(using gazebo-11, ros2-humble and python)



Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.