From 35cbf3b5dcd21e327922dbc16e5abae047da68c4 Mon Sep 17 00:00:00 2001 From: Pablo Dobarro Date: Mon, 20 Apr 2020 02:06:12 +0200 Subject: Fix crash on Multires Face Set visibility sync Multires uses the data of the Face Sets stored in the base mesh to manage the grid's visibility, so these pointers can no longer be set to NULL when editing Multires objects as they are requried for some operations. Reviewed By: sergey Differential Revision: https://developer.blender.org/D7431 --- source/blender/blenkernel/BKE_paint.h | 6 ++++++ 1 file changed, 6 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 f78a142704b..7822f285c3b 100644 --- a/source/blender/blenkernel/BKE_paint.h +++ b/source/blender/blenkernel/BKE_paint.h @@ -294,10 +294,15 @@ typedef struct SculptSession { struct MultiresModifierData *modifier; int level; } multires; + + /* These are always assigned to base mesh data when using PBVH_FACES and PBVH_GRIDS. */ struct MVert *mvert; struct MPoly *mpoly; struct MLoop *mloop; + + /* These contain the vertex and poly counts of the final mesh. */ int totvert, totpoly; + struct KeyBlock *shapekey_active; float *vmask; @@ -306,6 +311,7 @@ typedef struct SculptSession { int *pmap_mem; /* Mesh Face Sets */ + /* Total number of polys of the base mesh. */ int totfaces; int *face_sets; -- cgit v1.2.3