Commit: a60d0c60ab59de92f13407a4dec1104abccdfaf5
Author: Sergey Sharybin
Date:   Thu Nov 20 16:28:39 2014 +0100
Branches: depsgraph_refactor
https://developer.blender.org/rBa60d0c60ab59de92f13407a4dec1104abccdfaf5

Depsgraph: Corrected dependencies for hook modifier and bone parent

Victor rig is still broken tho..

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

M       source/blender/depsgraph/intern/depsgraph_build_relations.cpp
M       source/blender/modifiers/intern/MOD_hook.c

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

diff --git a/source/blender/depsgraph/intern/depsgraph_build_relations.cpp 
b/source/blender/depsgraph/intern/depsgraph_build_relations.cpp
index 92f8f1d..6a4f73b 100644
--- a/source/blender/depsgraph/intern/depsgraph_build_relations.cpp
+++ b/source/blender/depsgraph/intern/depsgraph_build_relations.cpp
@@ -296,14 +296,8 @@ void DepsgraphRelationBuilder::build_object_parent(Object 
*ob)
                        
                case PARBONE: /* Bone Parent */
                {
-#if 0
                        ComponentKey parent_key(&ob->parent->id, 
DEPSNODE_TYPE_BONE, ob->parsubstr);
                        add_relation(parent_key, ob_key, 
DEPSREL_TYPE_TRANSFORM, "Bone Parent");
-#else
-                       /* TODO(sergey): For until bones has real update 
funciton. */
-                       ComponentKey parent_key(&ob->parent->id, 
DEPSNODE_TYPE_TRANSFORM);
-                       add_relation(parent_key, ob_key, 
DEPSREL_TYPE_TRANSFORM, "Bone Parent");
-#endif
                }
                break;
                        
diff --git a/source/blender/modifiers/intern/MOD_hook.c 
b/source/blender/modifiers/intern/MOD_hook.c
index b96d30b..ec0e1c424 100644
--- a/source/blender/modifiers/intern/MOD_hook.c
+++ b/source/blender/modifiers/intern/MOD_hook.c
@@ -129,7 +129,8 @@ static void updateDepsgraph(ModifierData *md,
 
        if (hmd->object != NULL) {
                if (hmd->subtarget[0])
-                       DEG_add_object_relation(node, hmd->object, 
DEG_OB_COMP_GEOMETRY, "Hook Modifier");
+                       /* TODO(sergey): Hpw do we add relation to bone here? */
+                       DEG_add_object_relation(node, hmd->object, 
DEG_OB_COMP_EVAL_POSE, "Hook Modifier");
                else
                        DEG_add_object_relation(node, hmd->object, 
DEG_OB_COMP_TRANSFORM, "Hook Modifier");
        }

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to