Page MenuHome

Fix T73001: Shader Node properties controlled by driver not updating when driver property is animated
ClosedPublic

Authored by Sybren A. Stüvel (sybren) on Mon, Jan 13, 3:23 PM.

Details

Summary

This fixes T73001, but may inadvertently influence other areas as well, as it's in such a generic bit of code.

When there are ID properties on an object, and these are animated and used by a driver, the depsgraph has proper connections between ACTION → ID PROPERTY → DRIVER.

When these properties are defined on a mesh, however, the depsgraph relations are incorrectly created between GEOMETRY → PROPERTIES_EXIT → DRIVER (because it's assumed that 'source = ENTRY' implies 'geometry').

This patch solves this by first checking whether the targeted property is an ID property.

Diff Detail

Repository
rB Blender

Event Timeline

Think it should become:

if (prop != NULL && RNA_property_is_idprop(prop)) {
  ...
}
else if (ptr->type == &RNA_PoseBone) {
  ...

And remove is_idprop() case in bones and "fallback".
ID properties are supposed to have own nodes in PARAMETERS component, and i can not think of a case when ID property should point to something else than its own node.

source/blender/depsgraph/intern/builder/deg_builder_rna.cc
291

Can be DEG_DEBUG_PRINTF, or removed. Shouldn't be bare printf.

Sybren A. Stüvel (sybren) marked an inline comment as done.Fri, Jan 17, 5:28 PM
  • Feedback from Sergey
This revision is now accepted and ready to land.Fri, Jan 24, 12:03 PM