From e5d4afd5bac71e29ba71ecf091feaa0d70b70260 Mon Sep 17 00:00:00 2001 From: Jacques Lucke Date: Fri, 23 Sep 2022 12:39:56 +0200 Subject: Depsgraph: generalize passing parameters to depsgraph object iterator This makes it easier to pass more parameters to the iterator in the future. Differential Revision: https://developer.blender.org/D16047 --- source/blender/io/common/intern/abstract_hierarchy_iterator.cc | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'source/blender/io/common/intern/abstract_hierarchy_iterator.cc') diff --git a/source/blender/io/common/intern/abstract_hierarchy_iterator.cc b/source/blender/io/common/intern/abstract_hierarchy_iterator.cc index 1fbddc45964..03c1ba94d94 100644 --- a/source/blender/io/common/intern/abstract_hierarchy_iterator.cc +++ b/source/blender/io/common/intern/abstract_hierarchy_iterator.cc @@ -272,10 +272,11 @@ void AbstractHierarchyIterator::export_graph_construct() ExportGraph::key_type root_node_id = ObjectIdentifier::for_real_object(nullptr); export_graph_[root_node_id] = ExportChildren(); - DEG_OBJECT_ITER_BEGIN (depsgraph_, - object, - DEG_ITER_OBJECT_FLAG_LINKED_DIRECTLY | - DEG_ITER_OBJECT_FLAG_LINKED_VIA_SET) { + DEGObjectIterSettings deg_iter_settings{}; + deg_iter_settings.depsgraph = depsgraph_; + deg_iter_settings.flags = DEG_ITER_OBJECT_FLAG_LINKED_DIRECTLY | + DEG_ITER_OBJECT_FLAG_LINKED_VIA_SET; + DEG_OBJECT_ITER_BEGIN (°_iter_settings, object) { /* Non-instanced objects always have their object-parent as export-parent. */ const bool weak_export = mark_as_weak_export(object); visit_object(object, object->parent, weak_export); -- cgit v1.2.3