=== Transform ===
Fixed a bug with PET with connectivity, Mesh Face Select mode and Individual Centers. Those three together could give negative factors, which is a big no no (this is due to some approximation in the connectivity code). Clamping the factor makes everything fine. Bug reported by someone on BA
This commit is contained in:
@@ -830,6 +830,15 @@ void calculatePropRatio(TransInfo *t)
|
||||
/* Use rdist for falloff calculations, it is the real distance */
|
||||
td->flag &= ~TD_NOACTION;
|
||||
dist= (t->propsize-td->rdist)/t->propsize;
|
||||
|
||||
/*
|
||||
* Clamp to positive numbers.
|
||||
* Certain corner cases with connectivity and individual centers
|
||||
* can give values of rdist larger than propsize.
|
||||
*/
|
||||
if (dist < 0.0f)
|
||||
dist = 0.0f;
|
||||
|
||||
switch(G.scene->prop_mode) {
|
||||
case PROP_SHARP:
|
||||
td->factor= dist*dist;
|
||||
|
||||
Reference in New Issue
Block a user