diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2017-12-20 19:54:52 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2017-12-20 19:54:52 +0300 |
commit | 93b2871cf5c4a3c5346d9861c01b011021b7384d (patch) | |
tree | ca7bc3a108382a7b4715468a4e6ec34dc0bbfe57 /source/blender/depsgraph/intern/debug/deg_debug_graphviz.cc | |
parent | 5650fe77e4c2ba2f0717da6934c6038d490b802c (diff) |
Depsgraph: Remove node class stored in both type info and node
This is something deliver form node type, there is no reason to try cache it
anywhere, especially since it's not used in any performance critical code.
Lighter weight dependency graph is what we want.
Diffstat (limited to 'source/blender/depsgraph/intern/debug/deg_debug_graphviz.cc')
-rw-r--r-- | source/blender/depsgraph/intern/debug/deg_debug_graphviz.cc | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/source/blender/depsgraph/intern/debug/deg_debug_graphviz.cc b/source/blender/depsgraph/intern/debug/deg_debug_graphviz.cc index 159e9bcf9a7..6d8fda97321 100644 --- a/source/blender/depsgraph/intern/debug/deg_debug_graphviz.cc +++ b/source/blender/depsgraph/intern/debug/deg_debug_graphviz.cc @@ -115,7 +115,7 @@ static int deg_debug_node_color_index(const DepsNode *node) break; } /* Do others based on class. */ - switch (node->tclass) { + switch (node->get_class()) { case DEG_NODE_CLASS_OPERATION: return 4; case DEG_NODE_CLASS_COMPONENT: @@ -202,7 +202,7 @@ static void deg_debug_graphviz_node_color(const DebugContext &ctx, const char *color_update = "dodgerblue3"; const char *color = color_default; if (ctx.show_tags) { - if (node->tclass == DEG_NODE_CLASS_OPERATION) { + if (node->get_class() == DEG_NODE_CLASS_OPERATION) { OperationDepsNode *op_node = (OperationDepsNode *)node; if (op_node->flag & DEPSOP_FLAG_DIRECTLY_MODIFIED) { color = color_modified; @@ -223,7 +223,7 @@ static void deg_debug_graphviz_node_penwidth(const DebugContext &ctx, float penwidth_update = 4.0f; float penwidth = penwidth_default; if (ctx.show_tags) { - if (node->tclass == DEG_NODE_CLASS_OPERATION) { + if (node->get_class() == DEG_NODE_CLASS_OPERATION) { OperationDepsNode *op_node = (OperationDepsNode *)node; if (op_node->flag & DEPSOP_FLAG_DIRECTLY_MODIFIED) { penwidth = penwidth_modified; @@ -261,14 +261,14 @@ static void deg_debug_graphviz_node_style(const DebugContext &ctx, const DepsNod { const char *base_style = "filled"; /* default style */ if (ctx.show_tags) { - if (node->tclass == DEG_NODE_CLASS_OPERATION) { + if (node->get_class() == DEG_NODE_CLASS_OPERATION) { OperationDepsNode *op_node = (OperationDepsNode *)node; if (op_node->flag & (DEPSOP_FLAG_DIRECTLY_MODIFIED | DEPSOP_FLAG_NEEDS_UPDATE)) { base_style = "striped"; } } } - switch (node->tclass) { + switch (node->get_class()) { case DEG_NODE_CLASS_GENERIC: deg_debug_fprintf(ctx, "\"%s\"", base_style); break; @@ -293,7 +293,7 @@ static void deg_debug_graphviz_node_single(const DebugContext &ctx, BLI_snprintf(buf, sizeof(buf), " (Layers: %u)", id_node->layers); name += buf; } - if (ctx.show_eval_priority && node->tclass == DEG_NODE_CLASS_OPERATION) { + if (ctx.show_eval_priority && node->get_class() == DEG_NODE_CLASS_OPERATION) { priority = ((OperationDepsNode *)node)->eval_priority; } deg_debug_fprintf(ctx, "// %s\n", name.c_str()); @@ -440,7 +440,7 @@ static bool deg_debug_graphviz_is_cluster(const DepsNode *node) static bool deg_debug_graphviz_is_owner(const DepsNode *node, const DepsNode *other) { - switch (node->tclass) { + switch (node->get_class()) { case DEG_NODE_CLASS_COMPONENT: { ComponentDepsNode *comp_node = (ComponentDepsNode *)node; |