icub-tech-iit / ergocub-software

Main collector of ergoCub specific SW
https://icub-tech-iit.github.io/ergocub-software/
BSD 3-Clause "New" or "Revised" License
13 stars 18 forks source link

Add white diffuse color to the robot links for proper visualization in Modern Gazebo simulator #75

Closed paolo-viceconte closed 1 year ago

paolo-viceconte commented 1 year ago

When trying to visualize the ergoCub model in Ignition Gazebo, the robot is visualized all in white:

no_diffuse

This is instead the result if a white diffuse color is applied to all the robot links:

diffuse

The lines added to the urdf model to get the above can be found here.

This issue is to track the possibility of including these changes in the ergoCub urdf, since they can be of interest for future development in Ignition Gazebo.

cc @traversaro @S-Dafarra @GiulioRomualdi

Nicogene commented 1 year ago

I don't think it is possible to add it right now, I checked simmechanics-to-urdf but there is not any option that handles visuals, @traversaro correct me if I am wrong. I would open an issue there for adding this feature, even if we are working on creating our own creo2urdf converter

traversaro commented 1 year ago

I don't think it is possible to add it right now, I checked simmechanics-to-urdf but there is not any option that handles visuals, @traversaro correct me if I am wrong.

Yes, I am afraid is correct.

Anyhow, @paolo-viceconte which version of Ignition Gazebo (that is now known just as a Gazebo, or "Modern" Gazebo as I tipically refer to to avoid confusions) are you using? If even a simple URDF model with a cube shape is not displayed correctly, I have the impression that this is more a problem of default values in Modern Gazebo instead that of a problem on the models side.

paolo-viceconte commented 1 year ago

Anyhow, @paolo-viceconte which version of Ignition Gazebo (that is now known just as a Gazebo, or "Modern" Gazebo as I tipically refer to to avoid confusions) are you using? If even a simple URDF model with a cube shape is not displayed correctly, I have the impression that this is more a problem of default values in Modern Gazebo instead that of a problem on the models side.

Ok, this could be actually relevant, I should have documented it more properly. I am using an old version of Modern Gazebo built from source (whose versioning is documented here) in order to be compatible with a specific version of gym-ignition.

Most likely updated versions of Modern Gazebo are not affected by this issue, although I did not test it. I guess we can close this issue for the time being, and address it in the case it appears in more updated setups.

paolo-viceconte commented 1 year ago

Closing this for the time being, since it could be just related to a specific development setup. We will reopen it if it appears to be a more general issue.