From da8dc204bd062b2712869cf2709d2530915249b5 Mon Sep 17 00:00:00 2001 From: Philipp Oeser Date: Mon, 30 Nov 2020 16:45:47 +0100 Subject: Fix T83119: Crash with topology mirror affecting a hidden vertex Caused by rBba97da21acf2. For non-topology mirror hidden verts were never respected/included in EDBM_verts_mirror_cache_begin (they were excluded from the kdtree). Prior to said commit, hidden mirrored verts that were still in the map would have been excluded in a separate loop over vertices in 'editmesh_mirror_data_calc()' by checking BM_ELEM_HIDDEN. Due to the new nature of this function this check was now moved to EDBM_verts_mirror_cache_begin. Maniphest Tasks: T83119 Differential Revision: https://developer.blender.org/D9673 --- source/blender/editors/mesh/editmesh_utils.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'source/blender/editors/mesh/editmesh_utils.c') diff --git a/source/blender/editors/mesh/editmesh_utils.c b/source/blender/editors/mesh/editmesh_utils.c index d7ed3dca1b1..6467df0e87b 100644 --- a/source/blender/editors/mesh/editmesh_utils.c +++ b/source/blender/editors/mesh/editmesh_utils.c @@ -1139,6 +1139,9 @@ void EDBM_verts_mirror_cache_begin_ex(BMEditMesh *em, if (use_topology) { v_mirr = cache_mirr_intptr_as_bmvert(mesh_topo_store.index_lookup, i); + if (respecthide && BM_elem_flag_test(v_mirr, BM_ELEM_HIDDEN)) { + v_mirr = NULL; + } } else { int i_mirr; -- cgit v1.2.3