Fix T89331: Cycles lights flicker when transformed
The check on the transformation introduced in rBb313525c1bd0 to fix T88515 would sometimes prevent to update the light if the Blender object changed. To fix this, reverse the order in which the checks happen so that we do not shortcuit the object change check.
This commit is contained in:
parent
b964f73e7d
commit
befb9d99f8
Notes:
blender-bot
2023-02-14 08:08:56 +01:00
Referenced by issue #89331, Cycles - Lights flicker while being moved or rotated in viewport Referenced by issue #88515, Viewport Cycles does not update the position of lights from linked collections, from at least 2.91 to 2.93
|
@ -44,7 +44,7 @@ void BlenderSync::sync_light(BL::Object &b_parent,
|
|||
const bool tfm_updated = (light && light->get_tfm() != tfm);
|
||||
|
||||
/* Update if either object or light data changed. */
|
||||
if (!tfm_updated && !light_map.add_or_update(&light, b_ob, b_parent, key)) {
|
||||
if (!light_map.add_or_update(&light, b_ob, b_parent, key) && !tfm_updated) {
|
||||
Shader *shader;
|
||||
if (!shader_map.add_or_update(&shader, b_light)) {
|
||||
if (light->get_is_portal())
|
||||
|
|
Loading…
Reference in New Issue