[Bf-blender-cvs] [ea5cf3ff7ae] master: Depsgraph: Rework debug relations update function
Sergey Sharybin
noreply at git.blender.org
Wed Oct 25 12:13:29 CEST 2017
Commit: ea5cf3ff7ae9a20fda9d26159a8ada6c2970aa48
Author: Sergey Sharybin
Date: Wed Oct 25 12:11:49 2017 +0200
Branches: master
https://developer.blender.org/rBea5cf3ff7ae9a20fda9d26159a8ada6c2970aa48
Depsgraph: Rework debug relations update function
Make it a tag for relations update function instead, since we will not be able
to easily rebuild relations, and we wouldn't be able to iterate all scenes.
This is a part of mowing depsgraph to be per-workspace/layer in 2.8 branch.
===================================================================
M source/blender/makesrna/intern/rna_depsgraph.c
===================================================================
diff --git a/source/blender/makesrna/intern/rna_depsgraph.c b/source/blender/makesrna/intern/rna_depsgraph.c
index 4a53cea5f95..adb99acef1f 100644
--- a/source/blender/makesrna/intern/rna_depsgraph.c
+++ b/source/blender/makesrna/intern/rna_depsgraph.c
@@ -42,8 +42,7 @@
#ifdef RNA_RUNTIME
-#include "BKE_report.h"
-
+#include "DEG_depsgraph_build.h"
#include "DEG_depsgraph_debug.h"
static void rna_Depsgraph_debug_graphviz(Depsgraph *graph, const char *filename)
@@ -56,14 +55,9 @@ static void rna_Depsgraph_debug_graphviz(Depsgraph *graph, const char *filename)
fclose(f);
}
-static void rna_Depsgraph_debug_rebuild(Depsgraph *UNUSED(graph), Main *bmain)
+static void rna_Depsgraph_debug_tag_update(Depsgraph *graph)
{
- Scene *sce;
- DAG_relations_tag_update(bmain);
- for (sce = bmain->scene.first; sce; sce = sce->id.next) {
- DAG_scene_relations_rebuild(bmain, sce);
- DEG_graph_on_visible_update(bmain, sce);
- }
+ DEG_graph_tag_relations_update(graph);
}
static void rna_Depsgraph_debug_stats(Depsgraph *graph, char *result)
@@ -91,8 +85,7 @@ static void rna_def_depsgraph(BlenderRNA *brna)
"File in which to store graphviz debug output");
RNA_def_parameter_flags(parm, 0, PARM_REQUIRED);
- func = RNA_def_function(srna, "debug_rebuild", "rna_Depsgraph_debug_rebuild");
- RNA_def_function_flag(func, FUNC_USE_MAIN);
+ func = RNA_def_function(srna, "debug_tag_update", "rna_Depsgraph_debug_tag_update");
func = RNA_def_function(srna, "debug_stats", "rna_Depsgraph_debug_stats");
RNA_def_function_ui_description(func, "Report the number of elements in the Dependency Graph");
More information about the Bf-blender-cvs
mailing list