From 3ebe97c06b67d1611dfeaa3919512155416b0378 Mon Sep 17 00:00:00 2001 From: Pablo Dobarro Date: Mon, 27 Jul 2020 23:40:19 +0200 Subject: Fix T78665: Face Set visibility reverted when chaning Multires Levels Face Sets where only set and updated on the PBVH after starting a sculpt tool. In order to preserve the visibility they store when changing levels, they need to be updated and sync also on PBVH creation Reviewed By: sergey Maniphest Tasks: T78665 Differential Revision: https://developer.blender.org/D8225 --- source/blender/blenkernel/BKE_paint.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'source/blender/blenkernel/BKE_paint.h') diff --git a/source/blender/blenkernel/BKE_paint.h b/source/blender/blenkernel/BKE_paint.h index 1c02aece06f..de18ec6b792 100644 --- a/source/blender/blenkernel/BKE_paint.h +++ b/source/blender/blenkernel/BKE_paint.h @@ -471,6 +471,10 @@ struct PBVH *BKE_sculpt_object_pbvh_ensure(struct Depsgraph *depsgraph, struct O void BKE_sculpt_bvh_update_from_ccg(struct PBVH *pbvh, struct SubdivCCG *subdiv_ccg); +/* This ensure that all elements in the mesh (both vertices and grids) have their visibility + * updated according to the face sets. */ +void BKE_sculpt_sync_face_set_visibility(struct Mesh *mesh, struct SubdivCCG *subdiv_ccg); + bool BKE_sculptsession_use_pbvh_draw(const struct Object *ob, const struct View3D *v3d); enum { -- cgit v1.2.3