Depsgraph: Fix missing relation from node tree to light

Was only happening when lamp had driver on the Light datablock.

Reported by Dalai Felinto in T60137.
This commit is contained in:
Sergey Sharybin 2019-01-04 16:17:53 +01:00
parent b69cbe7d87
commit dfc0d3755b
1 changed files with 5 additions and 0 deletions

View File

@ -1442,6 +1442,11 @@ void DepsgraphNodeBuilder::build_lamp(Lamp *lamp)
DEG_NODE_TYPE_PARAMETERS,
NULL,
DEG_OPCODE_PARAMETERS_EVAL);
/* NOTE: We mark this node as both entry and exit. This way we have a
* node to link all dependencies for shading (which includes relation to the
* lamp object, and incldues relation from node tree) without adding a
* dedicated component type. */
op_node->set_as_entry();
op_node->set_as_exit();
/* lamp's nodetree */
build_nodetree(lamp->nodetree);