mujoco
mujoco copied to clipboard
Defaults/Classes for Body elements
Adding classes/defaults for body elements could make some MJCF models more compact. This could be used to set the gravcomp attribute for a kinematic chain for instance using the childclass attribute. Otherwise gravcomp has to be defined on every body of the chain.
+1
Yes, both bodies and sensors currently don't support defaults. This is a legitimate feature request.
This is unfortunately infeasible or rather, very hard. The "class" attribute of bodies is being reused for "childclass", so there is no way (without a significant refactor) to implement this.