[Bf-blender-cvs] [14931ef] depsgraph_refactor: Depsgraph: Allow transforming animated objects

Sergey Sharybin noreply at git.blender.org
Wed Nov 26 17:19:11 CET 2014


Commit: 14931ef1a1622499286a756388babf13feaafcce
Author: Sergey Sharybin
Date:   Wed Nov 26 15:14:17 2014 +0100
Branches: depsgraph_refactor
https://developer.blender.org/rB14931ef1a1622499286a756388babf13feaafcce

Depsgraph: Allow transforming animated objects

The issue was solved by skipping flush to animation component
when tagging ID block for an update. This seems to be reasonable
thing to do: animation should only be tagged directly when editing
in the animation editor or via the time source node update.

===================================================================

M	source/blender/depsgraph/intern/depsnode.cpp

===================================================================

diff --git a/source/blender/depsgraph/intern/depsnode.cpp b/source/blender/depsgraph/intern/depsnode.cpp
index 439b2bd..57266d3 100644
--- a/source/blender/depsgraph/intern/depsnode.cpp
+++ b/source/blender/depsgraph/intern/depsnode.cpp
@@ -193,7 +193,14 @@ void IDDepsNode::tag_update(Depsgraph *graph)
 {
 	for (ComponentMap::const_iterator it = components.begin(); it != components.end(); ++it) {
 		ComponentDepsNode *comp_node = it->second;
-		comp_node->tag_update(graph);
+		/* Animation component should only be tagged for update by the time updates,
+		 * or by tagging the animation itself.
+		 *
+		 * TODO(sergey): Make it faster than stupid string comparison.
+		 */
+		if (comp_node->name != "Animation Component") {
+			comp_node->tag_update(graph);
+		}
 	}
 }




More information about the Bf-blender-cvs mailing list