Skip to content

Commit

Permalink
mujoco add render backend documentation (#1183)
Browse files Browse the repository at this point in the history
  • Loading branch information
Kallinteris-Andreas authored Oct 1, 2024
1 parent 3c27a3e commit 5c9d694
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions docs/environments/mujoco.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,16 @@ env = gymnasium.make("Ant-v5", render_mode="rgb_array", width=1280, height=720)
| `max_geom` | **int** | `1000` | Max number of geometrical objects to render (useful for 3rd-party environments) |
| `visual_options` | **Dict[int, bool]** | `{}` | A dictionary with [mjVisual](https://mujoco.readthedocs.io/en/stable/overview.html#mjvisual) flags and value pairs, example `{mujoco.mjtVisFlag.mjVIS_CONTACTPOINT: True, mujoco.mjtVisFlag.mjVIS_CONTACTFORCE: True}` (show contact points and forces). |

### Rendering Backend
The MuJoCo simulator renders images with OpenGL and can use 3 different back ends "glfw" (default), "egl", "omesa", which can be selected by setting an [environment variable](https://en.wikipedia.org/wiki/Environment_variable).

| Backend | Environment Variable | Description |
|---------|----------------------------|-----------------------------------|
| `glfw` | `MUJOCO_GL=glfw` (default) | Renders with window System on GPU |
| `egl` | `MUJOCO_GL=egl` | Renders headless on GPU |
| `omesa` | `MUJOCO_GL=omesa` | Renders headless on CPU |

More information of the [MuJoCo/OpenGL documentation](https://mujoco.readthedocs.io/en/stable/programming/index.html#using-opengl).
<!--
## Custom Models
For more complex locomotion robot environments you can use third party models with the environments.
Expand Down

0 comments on commit 5c9d694

Please sign in to comment.