Commit: e20ed590371a40d1cef74e145634029dd4626e87
Author: Brecht Van Lommel
Date:   Tue Aug 28 12:43:13 2018 +0200
Branches: blender2.8
https://developer.blender.org/rBe20ed590371a40d1cef74e145634029dd4626e87

Fix T56530, T56523: collection visiblity toggling wrong after recent changes.

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

M       source/blender/depsgraph/intern/depsgraph_query_iter.cc

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

diff --git a/source/blender/depsgraph/intern/depsgraph_query_iter.cc 
b/source/blender/depsgraph/intern/depsgraph_query_iter.cc
index 3331389a1db..791e5edbfc6 100644
--- a/source/blender/depsgraph/intern/depsgraph_query_iter.cc
+++ b/source/blender/depsgraph/intern/depsgraph_query_iter.cc
@@ -163,6 +163,10 @@ 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;
 
+       if (!id_node->is_visible) {
+               return;
+       }
+
        DEGObjectIterData *data = (DEGObjectIterData *)iter->data;
        const ID_Type id_type = GS(id_node->id_orig->name);
 
@@ -298,7 +302,11 @@ static void DEG_iterator_ids_step(BLI_Iterator *iter, 
DEG::IDDepsNode *id_node,
 {
        ID *id_cow = id_node->id_cow;
 
-       if (only_updated && !(id_cow->recalc & ID_RECALC_ALL)) {
+       if (!id_node->is_visible) {
+               iter->skip = true;
+               return;
+       }
+       else if (only_updated && !(id_cow->recalc & ID_RECALC_ALL)) {
                bNodeTree *ntree = ntreeFromID(id_cow);
 
                /* Nodetree is considered part of the datablock. */

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to