Jump to content

Connect Leeroopedia MCP: Equip your AI agents to search best practices, build plans, verify code, diagnose failures, and look up hyperparameter defaults.

Implementation:Google deepmind Mujoco Platform GUI

From Leeroopedia
Knowledge Sources
Domains GUI, Simulation Visualization
Last Updated 2026-02-15 04:00 GMT

Overview

Implements ImGui-based GUI panels for MuJoCo physics settings, visualization options, rendering flags, and simulation control used by Studio and other applications.

Description

gui.cc provides a comprehensive set of ImGui panel-building functions for the MuJoCo platform layer. It includes SetupTheme which configures dark, light, and classic color themes with detailed per-element color customization. The file implements GUI panels for physics parameters (integrator, solver settings), visualization groups, rendering/visualization flags, and camera controls. Helper functions like GetFlexElementSize manage responsive layout calculations for multi-column ImGui elements.

Usage

Called by Studio's App class and other MuJoCo GUI applications to render the standard set of simulation control panels. Each panel function takes the relevant MuJoCo data structures (mjModel, mjvOption, mjvCamera, etc.) as parameters and mutates them based on user interaction.

Code Reference

Source Location

Key Functions

void SetupTheme(GuiTheme theme);
static ImVec2 GetFlexElementSize(int num_cols);
void PhysicsGui(mjModel* model, float min_width);
void GroupsGui(const mjModel* model, mjvOption* vis_options, float min_width);
void RenderingGui(const mjModel* model, mjvOption* vis_options, mjtByte* render_flags, float min_width);
void VisualizationGui(mjModel* model, mjvOption* vis_options, mjvCamera* camera, ...);

Import

#include "experimental/platform/gui.h"

I/O Contract

Inputs

Name Type Required Description
model mjModel* Yes MuJoCo model with physics and visualization parameters
vis_options mjvOption* Yes Visualization options (flags, groups)
camera mjvCamera* No Camera settings for visualization GUI
theme GuiTheme No Requested color theme (kDark, kLight, kClassic)

Outputs

Name Type Description
Modified model/options Various In-place modifications to model physics parameters, visualization flags, and camera settings

Related Pages

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment