Skip to content

2.1.2

Compare
Choose a tag to compare
@saran-t saran-t released this 15 Mar 14:59
· 2256 commits to main since this release

New modules

  1. Added new Python bindings, which can be installed via pip install mujoco, and imported as import mujoco.
  2. Added new Unity plug-in.
  3. Added a new introspect module, which provides reflection-like capability for MuJoCo's public API, currently describing functions and enums. While implemented in Python, this module is expected to be generally useful for automatic code generation targeting multiple languages. (This is not shipped as part of the mujoco Python bindings package.)

API changes

  1. Moved definition of mjtNum floating point type into a new header mjtnum.h.
  2. Renamed header mujoco_export.h to mjexport.h.
  3. Added mj_printFormattedData, which accepts a format string for floating point numbers, for example to increase precision.

General

  1. MuJoCo can load OBJ mesh files.
    • Meshes containing polygons with more than 4 vertices are not supported.
    • In OBJ files containing multiple object groups, any groups after the first one will be ignored.
  2. Added optional frame-of-reference specification to: framepos, framequat, framexaxis, frameyaxis, framezaxis, framelinvel, and frameangvel sensors. The frame-of-reference is specified by new reftype and refname attributes.
  3. Sizes of user parameters are now automatically inferred.
    • Declarations of user parameters in the top-level size clause (e.g. nuser_body, nuser_jnt, etc.) now accept a value of -1, which is the default. This will automatically set the value to the length of the maximum associated user attribute defined in the model.
    • Setting a value smaller than -1 will lead to a compiler error (previously a segfault).
    • Setting a value to a length smaller than some user attribute defined in the model will lead to an error (previously additional values were ignored).
  4. Increased the maximum number of lights in an mjvScene from 8 to 100.
  5. Saved XML files only contain explicit inertial elements if the original XML included them. Inertias that were automatically inferred by the compiler's inertiafromgeom mechanism remain unspecified.
  6. User-selected geoms are always rendered as opaque. This is useful in interactive visualizers.
  7. Static geoms now respect their geom group for visualisation. Until this change rendering of static geoms could only be toggled using the mjVIS_STATIC visualisation flag . After this change, both the geom group and the visualisation flag need to be enabled for the geom to be rendered.
  8. Pointer parameters in function declarations in mujoco.h that are supposed to represent fixed-length arrays are now spelled as arrays with extents, e.g. mjtNum quat[4] rather than mjtNum* quat. From the perspective of C and C++, this is a non-change since array types in function signatures decay to pointer types. However, it allows autogenerated code to be aware of expected input shapes.
  9. Experimental stateless fluid interaction model. As described here, fluid forces use sizes computed from body inertia. While sometimes convenient, this is very rarely a good approximation. In the new model forces act on geoms, rather than bodies, and have a several user-settable parameters. The model is activated by setting a new attribute: <geom fluidshape="ellipsoid"/>. The parameters are described succinctly here, but we leave a full description or the model and its parameters to when this feature leaves experimental status.

Bug Fixes

  1. mj_loadXML and mj_saveLastXML are now locale-independent. The Unity plugin should now work correctly for users whose system locales use commas as decimal separators.
  2. XML assets in VFS no longer need to end in a null character. Instead, the file size is determined by the size parameter of the corresponding VFS entry.
  3. Fix a vertex buffer object memory leak in mjrContext when skins are used.
  4. Camera quaternions are now normalized during XML compilation.

Binary build

  1. Windows binaries are now built with Clang.

Python bindings 2.1.2.post1 (16 March 2022)

  • Removed a stray print statement in __init__.py.
  • Bundled libglewegl.so for Linux now has a DT_NEEDED entry on libOpenGL.so.0. (The download packages for Linux below have also been updated with this.)
  • The sdist can now be built with GCC.