From 9b2b7cf92a26c9f06677daa49b333943df391338 Mon Sep 17 00:00:00 2001 From: Google DeepMind Date: Wed, 28 May 2025 07:46:43 -0700 Subject: [PATCH] Set light intensity to 0 by default (not 1000). PiperOrigin-RevId: 764257692 Change-Id: If656095e3f8d4b4d9c97fa67bdad508a49095eb3 --- doc/XMLreference.rst | 2 +- src/engine/engine_vis_visualize.c | 2 +- src/user/user_init.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/XMLreference.rst b/doc/XMLreference.rst index 2e716ca5..588235ab 100644 --- a/doc/XMLreference.rst +++ b/doc/XMLreference.rst @@ -2968,7 +2968,7 @@ Attributes may be applied or ignored depending on the lighting model being used. .. _body-light-intensity: -:at:`intensity`: :at-val:`real, "1000.0"` +:at:`intensity`: :at-val:`real, "0.0"` The intensity of the light source, measured in candela, used for physically-based lighting models. This is unused by the default Phong lighting model. diff --git a/src/engine/engine_vis_visualize.c b/src/engine/engine_vis_visualize.c index d0d57b3f..adcc410c 100644 --- a/src/engine/engine_vis_visualize.c +++ b/src/engine/engine_vis_visualize.c @@ -2147,7 +2147,7 @@ void mjv_makeLights(const mjModel* m, const mjData* d, mjvScene* scn) { thislight->type = mjLIGHT_DIRECTIONAL; thislight->castshadow = 0; thislight->bulbradius = 0.02; - thislight->intensity = 1000; + thislight->intensity = 0; thislight->range = 10; // compute head position and gaze direction in model space diff --git a/src/user/user_init.c b/src/user/user_init.c index fd8a7132..34199812 100644 --- a/src/user/user_init.c +++ b/src/user/user_init.c @@ -203,7 +203,7 @@ void mjs_defaultLight(mjsLight* light) { // intrinsics light->castshadow = 1; light->bulbradius = 0.02; - light->intensity = 1000.0; + light->intensity = 0.0; light->range = 10.0; light->active = 1; light->attenuation[0] = 1;