Parsing the SDFormat inertia auto=true attribute #21101
Labels
component: multibody parsing
Loading models into MultibodyPlant
priority: medium
type: feature request
Is your feature request related to a problem? Please describe.
There are situations like #20730 where users run an asset conversion tool to produce an SDFormat file. The tool emits redundant information (scaled geometry scale + density-based inertia). Later if the user decides the geometry scale is wrong, they might adjust that piece but forget to adjust the inertia.
Or even without such a conversion tool in play, it's onerous to have to type in the inertia just to get up and running with something sensible. We have fix_inertia that can help automate the process, but it still means dealing with manual file reprocessing and remembering to re-run the fixer any time you change the geometry.
Describe the solution you'd like
Implement the standardized attribute
<inertial auto="true">
so that inertia will be automatically calculated, instead of making the user type in numbers that they might have trouble describing correctly.Describe alternatives you've considered
Tell users to write MJCF files instead of SDFormat files. MJCF has better defaults, so the user doesn't need to opt-in to the
auto=true
logic.Additional context
There is a whole discussion about mesh calculation methods in the SDFormat specification. Someone should study it more carefully, but at first glance my reaction is that we should just use the same logic we already have for
fix_inertia
and direct-*.obj
parsing.Once we have this feature ready, we should probably upgrade
mesh_to_model
to use it. That way, it will be much safer for users to hand-edit the file afterwards.The text was updated successfully, but these errors were encountered: