diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2018-04-30 18:31:04 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2018-05-01 10:17:17 +0300 |
commit | 8cf9c58906f756bb556e0f290c9d005455502a6c (patch) | |
tree | f11bec62fd3d0bac42905896ae9e2418a832d66f | |
parent | 04ee606383107458717ed8f4197c07ca085c8668 (diff) |
Depsgraph: Put original and evaluated ID node pointers to graphviz
-rw-r--r-- | source/blender/depsgraph/intern/nodes/deg_node_id.cc | 9 | ||||
-rw-r--r-- | source/blender/depsgraph/intern/nodes/deg_node_id.h | 2 |
2 files changed, 11 insertions, 0 deletions
diff --git a/source/blender/depsgraph/intern/nodes/deg_node_id.cc b/source/blender/depsgraph/intern/nodes/deg_node_id.cc index edc5c0114f9..9f161db73ad 100644 --- a/source/blender/depsgraph/intern/nodes/deg_node_id.cc +++ b/source/blender/depsgraph/intern/nodes/deg_node_id.cc @@ -172,6 +172,15 @@ void IDDepsNode::destroy() id_orig = NULL; } +string IDDepsNode::identifier() const +{ + char orig_ptr[24], cow_ptr[24]; + BLI_snprintf(orig_ptr, sizeof(orig_ptr), "%p", id_orig); + BLI_snprintf(cow_ptr, sizeof(cow_ptr), "%p", id_cow); + return string(nodeTypeAsString(type)) + " : " + name + + " (orig: " + orig_ptr + ", eval: " + cow_ptr + ")"; +} + ComponentDepsNode *IDDepsNode::find_component(eDepsNode_Type type, const char *name) const { diff --git a/source/blender/depsgraph/intern/nodes/deg_node_id.h b/source/blender/depsgraph/intern/nodes/deg_node_id.h index 505a1129192..12dbc16b4fa 100644 --- a/source/blender/depsgraph/intern/nodes/deg_node_id.h +++ b/source/blender/depsgraph/intern/nodes/deg_node_id.h @@ -51,6 +51,8 @@ struct IDDepsNode : public DepsNode { ~IDDepsNode(); void destroy(); + virtual string identifier() const; + ComponentDepsNode *find_component(eDepsNode_Type type, const char *name = "") const; ComponentDepsNode *add_component(eDepsNode_Type type, |