Fix #135432: Cycles world light and shadow catcher bug after recent changes

Caused by #134846, e813e46327.

Pull Request: https://projects.blender.org/blender/blender/pulls/135440
This commit is contained in:
Brecht Van Lommel
2025-03-05 16:27:49 +01:00
committed by Brecht Van Lommel
parent 077115e936
commit 65889672e2
2 changed files with 5 additions and 1 deletions

View File

@@ -120,6 +120,10 @@ void BlenderSync::sync_background_light(BL::SpaceView3D &b_v3d)
Object *object;
const ObjectKey object_key(b_world, nullptr, b_world, false);
bool update = object_map.add_or_update(&object, b_world, b_world, object_key);
if (update) {
/* Lights should be shadow catchers by default. */
object->set_is_shadow_catcher(true);
}
/* Create geometry. */
const GeometryKey geom_key{b_world.ptr.data, Geometry::LIGHT};