Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source/blender/depsgraph/intern/builder/deg_builder_relations.cc7
1 files changed, 6 insertions, 1 deletions
diff --git a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc
index 26839c67324..c0630cd47c6 100644
--- a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc
+++ b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc
@@ -1489,6 +1489,9 @@ void DepsgraphRelationBuilder::build_driver_data(ID *id, FCurve *fcu)
return;
}
+ const char *prop_identifier = RNA_property_identifier(property_entry_key.prop);
+ const bool driver_targets_bbone = STRPREFIX(prop_identifier, "bbone_");
+
/* Find objects which use this, and make their eval callbacks depend on this. */
for (IDNode *to_node : graph_->id_nodes) {
if (GS(to_node->id_orig->name) != ID_OB) {
@@ -1506,7 +1509,9 @@ void DepsgraphRelationBuilder::build_driver_data(ID *id, FCurve *fcu)
continue;
}
- OperationKey bone_key(&object->id, NodeType::BONE, pchan->name, OperationCode::BONE_LOCAL);
+ OperationCode target_op = driver_targets_bbone ? OperationCode::BONE_SEGMENTS :
+ OperationCode::BONE_LOCAL;
+ OperationKey bone_key(&object->id, NodeType::BONE, pchan->name, target_op);
add_relation(driver_key, bone_key, "Arm Bone -> Driver -> Bone");
}
/* Make the driver depend on COW, similar to the generic case below. */