diff options
author | Dalai Felinto <dfelinto@gmail.com> | 2018-06-08 18:51:08 +0300 |
---|---|---|
committer | Dalai Felinto <dfelinto@gmail.com> | 2018-06-08 18:52:49 +0300 |
commit | f8d7df6f162520ee4da46f54d863c45a2b78cc8c (patch) | |
tree | 6b46df64f700bf129ee1b832b390e28937d22cab /source/blender/blenkernel | |
parent | f2fd5987d0f592567f1da8d080e5fe38acb12ec8 (diff) |
Depsgraph: Remove no longer needed nodetree values copying on eval
Note: Depsgraph still calls the nodetree eval function that doesn't
nothing in turn. We can remove it, but it is harmless though.
Diffstat (limited to 'source/blender/blenkernel')
-rw-r--r-- | source/blender/blenkernel/BKE_node.h | 3 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/node.c | 34 |
2 files changed, 0 insertions, 37 deletions
diff --git a/source/blender/blenkernel/BKE_node.h b/source/blender/blenkernel/BKE_node.h index 915cafd5d3d..cb211b65948 100644 --- a/source/blender/blenkernel/BKE_node.h +++ b/source/blender/blenkernel/BKE_node.h @@ -1056,9 +1056,6 @@ void free_nodesystem(void); struct Depsgraph; -void BKE_nodetree_copy_default_values(struct bNodeTree *ntree_dst, - const struct bNodeTree *ntree_src); - void BKE_nodetree_shading_params_eval(struct Depsgraph *depsgraph, struct bNodeTree *ntree_dst, const struct bNodeTree *ntree_src); diff --git a/source/blender/blenkernel/intern/node.c b/source/blender/blenkernel/intern/node.c index 7a1f6c5d2b6..bf25306028f 100644 --- a/source/blender/blenkernel/intern/node.c +++ b/source/blender/blenkernel/intern/node.c @@ -3739,43 +3739,9 @@ void BKE_nodetree_remove_layer_n(bNodeTree *ntree, Scene *scene, const int layer } } -static void node_copy_default_values_list(ListBase *sockets_dst, - const ListBase *sockets_src) -{ - bNodeSocket *sock_dst = sockets_dst->first; - const bNodeSocket *sock_src = sockets_src->first; - while (sock_dst != NULL) { - node_socket_copy_default_value(sock_dst, sock_src); - sock_dst = sock_dst->next; - sock_src = sock_src->next; - } -} - -static void node_copy_default_values(bNode *node_dst, const bNode *node_src) -{ - node_copy_default_values_list(&node_dst->inputs, &node_src->inputs); - node_copy_default_values_list(&node_dst->outputs, &node_src->outputs); -} - -void BKE_nodetree_copy_default_values(bNodeTree *ntree_dst, - const bNodeTree *ntree_src) -{ - if (ntree_dst == ntree_src) { - return; - } - bNode *node_dst = ntree_dst->nodes.first; - const bNode *node_src = ntree_src->nodes.first; - while (node_dst != NULL) { - node_copy_default_values(node_dst, node_src); - node_dst = node_dst->next; - node_src = node_src->next; - } -} - void BKE_nodetree_shading_params_eval(struct Depsgraph *depsgraph, bNodeTree *ntree_dst, const bNodeTree *ntree_src) { DEG_debug_print_eval(depsgraph, __func__, ntree_src->id.name, ntree_dst); - BKE_nodetree_copy_default_values(ntree_dst, ntree_src); } |