Fix T104176: Smooth modifier with vergex group not work for negative factors.
Regression from rBabc8d6b12ce9, over three years ago! Should be backported to the active LTS releases too.
This commit is contained in:
parent
3d765f6527
commit
9f866a92dc
Notes:
blender-bot
2023-02-14 12:01:57 +01:00
Referenced by issue #88449: Blender LTS: Maintenance Task 2.93 Referenced by issue #88449, Blender LTS: Maintenance Task 2.93 Referenced by issue #100749, Blender LTS: Maintenance Task 3.3 Referenced by issue #104176, Regession: Smooth modifier with vergex group not work for negative factors
|
@ -134,12 +134,12 @@ static void smoothModifier_do(
|
|||
}
|
||||
float *vco_new = accumulated_vecs[i];
|
||||
|
||||
const float f_new = invert_vgroup ?
|
||||
(1.0f - BKE_defvert_find_weight(dv, defgrp_index)) * fac_new :
|
||||
BKE_defvert_find_weight(dv, defgrp_index) * fac_new;
|
||||
if (f_new <= 0.0f) {
|
||||
const float f_vgroup = invert_vgroup ? (1.0f - BKE_defvert_find_weight(dv, defgrp_index)) :
|
||||
BKE_defvert_find_weight(dv, defgrp_index);
|
||||
if (f_vgroup <= 0.0f) {
|
||||
continue;
|
||||
}
|
||||
const float f_new = f_vgroup * fac_new;
|
||||
const float f_orig = 1.0f - f_new;
|
||||
|
||||
if (flag & MOD_SMOOTH_X) {
|
||||
|
|
Loading…
Reference in New Issue