Closed GiulioRomualdi closed 2 years ago
Yes, we can:
simmechanics-to-urdf
(just to set a user-specify color with an option, or just remove the random color behaviour, in case modify https://github.com/robotology/simmechanics-to-urdf/blob/f6055ab8d627c45138ddde46532ea42a74b48caa/simmechanics_to_urdf/firstgen.py#L1116), and switch icub-model-generator to use the new version of simmechanics-to-urdf
or:Both options are fine for me. We also need to identify which color we want to use.
Note that simmechanics-to-urdf already have a similar option (see https://github.com/robotology/simmechanics-to-urdf/blob/f6055ab8d627c45138ddde46532ea42a74b48caa/simmechanics_to_urdf/firstgen.py#L1116), but that would require to add a line in the yaml for each link to set a different color, so it may not be super-convenient.
Note that simmechanics-to-urdf already have a similar option (see https://github.com/robotology/simmechanics-to-urdf/blob/f6055ab8d627c45138ddde46532ea42a74b48caa/simmechanics_to_urdf/firstgen.py#L1116), but that would require to add a line in the yaml for each link to set a different color, so it may not be super-convenient.
I actually noticed that this dictionary is filled by the xml
file and not by the yaml file: From here -> here -> finally here
As far as I understood the xml
file is generated by simmechanics and it cannot be modified.
Should I replicate the same logic for the yaml
file?
Note that simmechanics-to-urdf already have a similar option (see https://github.com/robotology/simmechanics-to-urdf/blob/f6055ab8d627c45138ddde46532ea42a74b48caa/simmechanics_to_urdf/firstgen.py#L1116), but that would require to add a line in the yaml for each link to set a different color, so it may not be super-convenient.
I actually noticed that this dictionary is filled by the
xml
file and not by the yaml file: From here -> here -> finally hereAs far as I understood the
xml
file is generated by simmechanics and it cannot be modified.
You are right, I misunderstood the code.
Should I replicate the same logic for the
yaml
file?
I guess not, until we have a need for it.
https://github.com/robotology/icub-models-generator/pull/217 attempts to close this issue
Thanks to https://github.com/robotology/idyntree/pull/961 it will be possible to display the icub models with the colors defined in the
urdf
files.I noticed that the robot colors are "randomly" chosen when the model is generated. As a consequence, the representation of the model is a bit bizarre
This is how TALOS is loaded by the very same visualizer
Do you think it's possible to fix the color of the links?
cc @traversaro