Fix T72584: Hiding a collection don't hide a child object in viewport when in Local View
Hiding a collection should hide all children objects even when we are in Local view with one of them. Note from reviewer: We are doing this already for local collections. So may as well do it when hiding the collections for the entire view layer. Developer details: In function "BKE_object_is_visible_in_viewport" object flag BASE_VISIBLE_VIEWLAYER wasn't being checked when we were in Local view, It's now changed so that it's checked even if we are in Local view. And this function was called by some viewport draw functions to check if it should draw an object or not. Maniphest Tasks: T72584 Differential Revision: https://developer.blender.org/D7894
This commit is contained in:
committed by
Dalai Felinto
parent
0f61b27e93
commit
9bc1d7a6de
@@ -1111,8 +1111,8 @@ bool BKE_object_is_visible_in_viewport(const View3D *v3d, const struct Object *o
|
||||
return false;
|
||||
}
|
||||
|
||||
/* If not using local view or local collection the object may still be in a hidden collection. */
|
||||
if (((v3d->localvd) == NULL) && ((v3d->flag & V3D_LOCAL_COLLECTIONS) == 0)) {
|
||||
/* If not using local collection the object may still be in a hidden collection. */
|
||||
if ((v3d->flag & V3D_LOCAL_COLLECTIONS) == 0) {
|
||||
return (ob->base_flag & BASE_VISIBLE_VIEWLAYER) != 0;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user