diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2018-06-12 10:46:00 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2018-06-12 15:30:50 +0300 |
commit | abdea5754e641a3b66171c90c2ee1ac151225d10 (patch) | |
tree | bb69f2cb333661429fcb966fdedee47a3ca188a8 /source/blender/depsgraph/intern/depsgraph_query_iter.cc | |
parent | 43eebdfebd6e31d188ae3c1b220c8991fc869df3 (diff) |
Depsgraph: Cleanup, wrap private functions to an anonymous namespace
Diffstat (limited to 'source/blender/depsgraph/intern/depsgraph_query_iter.cc')
-rw-r--r-- | source/blender/depsgraph/intern/depsgraph_query_iter.cc | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/source/blender/depsgraph/intern/depsgraph_query_iter.cc b/source/blender/depsgraph/intern/depsgraph_query_iter.cc index 5dca0e83124..712ada44b7e 100644 --- a/source/blender/depsgraph/intern/depsgraph_query_iter.cc +++ b/source/blender/depsgraph/intern/depsgraph_query_iter.cc @@ -62,7 +62,9 @@ extern "C" { /* ************************ DEG ITERATORS ********************* */ -static void verify_id_proeprties_freed(DEGObjectIterData *data) +namespace { + +void verify_id_proeprties_freed(DEGObjectIterData *data) { if (data->dupli_object_current == NULL) { // We didn't enter duplication yet, so we can't have any dangling @@ -86,7 +88,7 @@ static void verify_id_proeprties_freed(DEGObjectIterData *data) temp_dupli_object->id.properties = NULL; } -static bool deg_objects_dupli_iterator_next(BLI_Iterator *iter) +bool deg_objects_dupli_iterator_next(BLI_Iterator *iter) { DEGObjectIterData *data = (DEGObjectIterData *)iter->data; while (data->dupli_object_next != NULL) { @@ -137,7 +139,7 @@ static bool deg_objects_dupli_iterator_next(BLI_Iterator *iter) return false; } -static void DEG_iterator_objects_step(BLI_Iterator *iter, DEG::IDDepsNode *id_node) +void deg_iterator_objects_step(BLI_Iterator *iter, DEG::IDDepsNode *id_node) { /* Set it early in case we need to exit and we are running from within a loop. */ iter->skip = true; @@ -191,6 +193,8 @@ static void DEG_iterator_objects_step(BLI_Iterator *iter, DEG::IDDepsNode *id_no iter->skip = false; } +} // namespace + void DEG_iterator_objects_begin(BLI_Iterator *iter, DEGObjectIterData *data) { Depsgraph *depsgraph = data->graph; @@ -217,7 +221,7 @@ void DEG_iterator_objects_begin(BLI_Iterator *iter, DEGObjectIterData *data) : OB_VISIBILITY_CHECK_FOR_VIEWPORT; DEG::IDDepsNode *id_node = deg_graph->id_nodes[data->id_node_index]; - DEG_iterator_objects_step(iter, id_node); + deg_iterator_objects_step(iter, id_node); if (iter->skip) { DEG_iterator_objects_next(iter); @@ -252,7 +256,7 @@ void DEG_iterator_objects_next(BLI_Iterator *iter) } DEG::IDDepsNode *id_node = deg_graph->id_nodes[data->id_node_index]; - DEG_iterator_objects_step(iter, id_node); + deg_iterator_objects_step(iter, id_node); } while (iter->skip); } |