From 18b594075c5a809a324ded569992a66af7d6f355 Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Mon, 12 Feb 2024 12:52:43 +0100 Subject: [PATCH] Fix #118034: Cycles: Driven View Layer property not considered in realtime The issue was caused by Cycles doing dependency tracking on its side, relying on the fact that view layer needs to be tagged as modified when its properties change. This was not the case when custom property on the a view layer is modified via a driver. Now the dependency graph will tag IDs which generic properties did change as ID_RECALC_PARAMETERS, giving it a chance to render engines to react to it. Since this is quite generic code which might have unforeseen side effects the change is not targeted to the current release branch. Note that this chaneg does not fix the #103140, as the issue there is use of RNA path to another data-block, without the node tree registering relation to that data-block. Pull Request: https://projects.blender.org/blender/blender/pulls/118134 --- source/blender/depsgraph/intern/node/deg_node_component.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/blender/depsgraph/intern/node/deg_node_component.cc b/source/blender/depsgraph/intern/node/deg_node_component.cc index 311dd5500a9..f05d056d143 100644 --- a/source/blender/depsgraph/intern/node/deg_node_component.cc +++ b/source/blender/depsgraph/intern/node/deg_node_component.cc @@ -323,7 +323,7 @@ DEG_COMPONENT_NODE_DEFINE(CopyOnWrite, COPY_ON_WRITE, ID_RECALC_COPY_ON_WRITE); DEG_COMPONENT_NODE_DEFINE(ImageAnimation, IMAGE_ANIMATION, 0); DEG_COMPONENT_NODE_DEFINE(Geometry, GEOMETRY, ID_RECALC_GEOMETRY); DEG_COMPONENT_NODE_DEFINE(LayerCollections, LAYER_COLLECTIONS, 0); -DEG_COMPONENT_NODE_DEFINE(Parameters, PARAMETERS, 0); +DEG_COMPONENT_NODE_DEFINE(Parameters, PARAMETERS, ID_RECALC_PARAMETERS); DEG_COMPONENT_NODE_DEFINE(Particles, PARTICLE_SYSTEM, ID_RECALC_GEOMETRY); DEG_COMPONENT_NODE_DEFINE(ParticleSettings, PARTICLE_SETTINGS, 0); DEG_COMPONENT_NODE_DEFINE(PointCache, POINT_CACHE, 0);