[Bf-blender-cvs] [7265f6c25ca] temp-dynamic-overrides: Depsgraph: Tag depsgraph id based on id type

Dalai Felinto noreply at git.blender.org
Sun May 27 19:23:53 CEST 2018


Commit: 7265f6c25caf8463b29a649275cbb1b573c905c8
Author: Dalai Felinto
Date:   Sun May 27 19:20:32 2018 +0200
Branches: temp-dynamic-overrides
https://developer.blender.org/rB7265f6c25caf8463b29a649275cbb1b573c905c8

Depsgraph: Tag depsgraph id based on id type

===================================================================

M	source/blender/depsgraph/DEG_depsgraph.h
M	source/blender/depsgraph/intern/depsgraph_tag.cc

===================================================================

diff --git a/source/blender/depsgraph/DEG_depsgraph.h b/source/blender/depsgraph/DEG_depsgraph.h
index 589df5df878..2c213b8d3cb 100644
--- a/source/blender/depsgraph/DEG_depsgraph.h
+++ b/source/blender/depsgraph/DEG_depsgraph.h
@@ -173,6 +173,11 @@ void DEG_graph_id_tag_update(struct Main *bmain,
  */
 void DEG_id_type_tag(struct Main *bmain, short id_type);
 
+void DEG_graph_id_type_tag_update(struct Main *bmain,
+                                  struct Depsgraph *depsgraph,
+                                  short id_type,
+                                  int flag);
+
 void DEG_ids_clear_recalc(struct Main *bmain);
 
 /* Update Flushing ------------------------------- */
diff --git a/source/blender/depsgraph/intern/depsgraph_tag.cc b/source/blender/depsgraph/intern/depsgraph_tag.cc
index 466e6053ef3..b8f6fcc6ae7 100644
--- a/source/blender/depsgraph/intern/depsgraph_tag.cc
+++ b/source/blender/depsgraph/intern/depsgraph_tag.cc
@@ -592,6 +592,14 @@ void DEG_id_type_tag(Main *bmain, short id_type)
 	bmain->id_tag_update[BKE_idcode_to_index(id_type)] = 1;
 }
 
+void DEG_graph_id_type_tag_update(Main *bmain, Depsgraph *depsgraph, short id_type, int flag)
+{
+	ListBase *data = BKE_idtype_to_main_data(bmain, id_type);
+	LISTBASE_FOREACH (ID *, id, data) {
+		DEG_graph_id_tag_update(bmain, depsgraph, id, flag);
+	}
+}
+
 void DEG_graph_flush_update(Main *bmain, Depsgraph *depsgraph)
 {
 	if (depsgraph == NULL) {



More information about the Bf-blender-cvs mailing list