diff options
author | Campbell Barton <ideasman42@gmail.com> | 2014-06-18 09:16:01 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2014-06-18 09:20:55 +0400 |
commit | 2ccbdec6e5c1cb97e19a142dfe5c1255e8ec3bf0 (patch) | |
tree | 789d2db6c27d25335f8b7cb8d6dbc862b9581865 /source/blender | |
parent | f0a3ea54f86256c229735c5766e9edfe8ba2acd4 (diff) |
Transform: PET only treat faces as connected diagonally across quads
Was an intentional change, but worse for concave ngons, resolves T40675
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/editors/transform/transform_conversions.c | 20 |
1 files changed, 8 insertions, 12 deletions
diff --git a/source/blender/editors/transform/transform_conversions.c b/source/blender/editors/transform/transform_conversions.c index d582a0c53de..72ac4ad8fcb 100644 --- a/source/blender/editors/transform/transform_conversions.c +++ b/source/blender/editors/transform/transform_conversions.c @@ -1916,20 +1916,16 @@ static void editmesh_set_connectivity_distance(BMesh *bm, float mtx[3][3], float } } - /* connected face-verts (excluding adjacent verts) */ + /* imaginary edge diagonally across quad */ BM_ITER_ELEM (l, &iter, v, BM_LOOPS_OF_VERT) { - if ((BM_elem_flag_test(l->f, BM_ELEM_HIDDEN) == 0) && (l->f->len > 3)) { - BMLoop *l_end = l->prev; - l = l->next->next; - do { - BMVert *v_other = l->v; - if (bmesh_test_dist_add(v, v_other, dists, dists_prev, mtx)) { - if (BM_elem_flag_test(v_other, BM_ELEM_TAG) == 0) { - BM_elem_flag_enable(v_other, BM_ELEM_TAG); - BLI_LINKSTACK_PUSH(queue_next, v_other); - } + if ((BM_elem_flag_test(l->f, BM_ELEM_HIDDEN) == 0) && (l->f->len == 4)) { + BMVert *v_other = l->next->next->v; + if (bmesh_test_dist_add(v, v_other, dists, dists_prev, mtx)) { + if (BM_elem_flag_test(v_other, BM_ELEM_TAG) == 0) { + BM_elem_flag_enable(v_other, BM_ELEM_TAG); + BLI_LINKSTACK_PUSH(queue_next, v_other); } - } while ((l = l->next) != l_end); + } } } } |