Fix #134286: Weight paint mirror ignores selection in face-select mode
Since the vert selection attribute should be in sync with face masking, we can just enter the codepath for selected vertices here. Pull Request: https://projects.blender.org/blender/blender/pulls/134327
This commit is contained in:
committed by
Philipp Oeser
parent
41bb42d374
commit
351aef120f
@@ -2066,8 +2066,7 @@ void vgroup_mirror(Object *ob,
|
||||
int *r_totmirr,
|
||||
int *r_totfail)
|
||||
{
|
||||
/* TODO: vgroup locking.
|
||||
* TODO: face masking. */
|
||||
/* TODO: vgroup locking. */
|
||||
|
||||
const int def_nr = BKE_object_defgroup_active_index_get(ob) - 1;
|
||||
int totmirr = 0, totfail = 0;
|
||||
@@ -2156,8 +2155,8 @@ void vgroup_mirror(Object *ob,
|
||||
}
|
||||
else {
|
||||
/* object mode / weight paint */
|
||||
const bool use_vert_sel = (mesh->editflag & ME_EDIT_PAINT_VERT_SEL) != 0;
|
||||
|
||||
const bool use_sel = (mesh->editflag & (ME_EDIT_PAINT_FACE_SEL | ME_EDIT_PAINT_VERT_SEL)) !=
|
||||
0;
|
||||
if (mesh->deform_verts().is_empty()) {
|
||||
goto cleanup;
|
||||
}
|
||||
@@ -2174,8 +2173,8 @@ void vgroup_mirror(Object *ob,
|
||||
if ((vidx_mirr = mesh_get_x_mirror_vert(ob, nullptr, vidx, use_topology)) != -1) {
|
||||
if (vidx != vidx_mirr) {
|
||||
if (!BLI_BITMAP_TEST(vert_tag, vidx_mirr)) {
|
||||
const bool sel = use_vert_sel ? select_vert[vidx] : true;
|
||||
const bool sel_mirr = use_vert_sel ? select_vert[vidx_mirr] : true;
|
||||
const bool sel = use_sel ? select_vert[vidx] : true;
|
||||
const bool sel_mirr = use_sel ? select_vert[vidx_mirr] : true;
|
||||
|
||||
if (sel || sel_mirr) {
|
||||
dvert_mirror_op(&dverts[vidx],
|
||||
|
||||
Reference in New Issue
Block a user