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_nodes.cc7
-rw-r--r--source/blender/depsgraph/intern/builder/deg_builder_relations.cc5
-rw-r--r--source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc3
-rw-r--r--source/blender/editors/animation/keyframing.c4
4 files changed, 16 insertions, 3 deletions
diff --git a/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc b/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc
index cbe11f8d7fa..3c7740e62fd 100644
--- a/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc
+++ b/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc
@@ -677,12 +677,17 @@ void DepsgraphNodeBuilder::build_animdata(ID *id)
if (adt == NULL) {
return;
}
-
/* animation */
if (adt->action || adt->nla_tracks.first || adt->drivers.first) {
(void) add_id_node(id);
ID *id_cow = get_cow_id(id);
+ if (adt->action != NULL) {
+ add_operation_node(&adt->action->id, DEG_NODE_TYPE_ANIMATION,
+ NULL,
+ DEG_OPCODE_ANIMATION);
+ }
+
// XXX: Hook up specific update callbacks for special properties which
// may need it...
diff --git a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc
index 5514d4b9452..c862b0e7af4 100644
--- a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc
+++ b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc
@@ -898,6 +898,11 @@ void DepsgraphRelationBuilder::build_animdata_curves(ID *id)
ComponentKey adt_key(id, DEG_NODE_TYPE_ANIMATION);
TimeSourceKey time_src_key;
add_relation(time_src_key, adt_key, "TimeSrc -> Animation");
+ /* Relation from action itself. */
+ if (adt->action != NULL) {
+ ComponentKey action_key(&adt->action->id, DEG_NODE_TYPE_ANIMATION);
+ add_relation(action_key, adt_key, "Action -> Animation");
+ }
/* Get source operations. */
DepsNode *node_from = get_node(adt_key);
BLI_assert(node_from != NULL);
diff --git a/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc b/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
index cb03c0dc92c..c149218a204 100644
--- a/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
+++ b/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
@@ -45,6 +45,7 @@
#include <cstring>
#include "BLI_utildefines.h"
+#include "BLI_listbase.h"
#include "BLI_threads.h"
#include "BLI_string.h"
@@ -61,6 +62,7 @@
extern "C" {
#include "DNA_ID.h"
+#include "DNA_anim_types.h"
#include "DNA_mesh_types.h"
#include "DNA_scene_types.h"
#include "DNA_object_types.h"
@@ -329,7 +331,6 @@ static bool check_datablocks_copy_on_writable(const ID *id_orig)
}
return !ELEM(id_type, ID_BR,
ID_LS,
- ID_AC,
ID_PAL);
}
diff --git a/source/blender/editors/animation/keyframing.c b/source/blender/editors/animation/keyframing.c
index b490ae9c097..7b637e5b725 100644
--- a/source/blender/editors/animation/keyframing.c
+++ b/source/blender/editors/animation/keyframing.c
@@ -159,7 +159,9 @@ bAction *verify_adt_action(ID *id, short add)
/* XXX: we probably should have bmain passed down, but that involves altering too many API's */
DEG_relations_tag_update(G.main);
}
-
+
+ DEG_id_tag_update(&adt->action->id, DEG_TAG_COPY_ON_WRITE);
+
/* return the action */
return adt->action;
}