Depsgraph: Remove workaround of parameters animation in lamp
authorSergey Sharybin <sergey.vfx@gmail.com>
Tue, 5 Dec 2017 15:43:27 +0000 (16:43 +0100)
committerSergey Sharybin <sergey.vfx@gmail.com>
Wed, 6 Dec 2017 09:21:33 +0000 (10:21 +0100)
source/blender/depsgraph/intern/builder/deg_builder_relations.cc

index e52902b8c8ad9b072acca4953030c069111abc21..1f384e35fc8eca9f289114c45d904c2f14f7ecd5 100644 (file)
@@ -1648,21 +1648,13 @@ void DepsgraphRelationBuilder::build_lamp(Object *object)
                return;
        }
        lamp_id->tag |= LIB_TAG_DOIT;
-
-       ComponentKey parameters_key(lamp_id, DEG_NODE_TYPE_PARAMETERS);
-
-       if (needs_animdata_node(lamp_id)) {
-               ComponentKey animation_key(lamp_id, DEG_NODE_TYPE_ANIMATION);
-               add_relation(animation_key, parameters_key, "Lamp Parameters");
-       }
-
        /* lamp's nodetree */
-       if (la->nodetree) {
+       if (la->nodetree != NULL) {
                build_nodetree(la->nodetree);
+               ComponentKey parameters_key(lamp_id, DEG_NODE_TYPE_PARAMETERS);
                ComponentKey nodetree_key(&la->nodetree->id, DEG_NODE_TYPE_PARAMETERS);
                add_relation(nodetree_key, parameters_key, "NTree->Lamp Parameters");
        }
-
        /* textures */
        build_texture_stack(la->mtex);
 }