Fix T93163: GPencil scale thickness fails in negative scales

Before the negative scales produced a thickness invalid. Now, the value is used in absolute value to avoid this situation.
This commit is contained in:
2021-12-30 11:17:55 +01:00
parent 0b73b2c6cf
commit 49a18cc91e

View File

@@ -1042,7 +1042,7 @@ void ElementResize(const TransInfo *t,
applyNumInput(&num_evil, values_final_evil);
float ratio = values_final_evil[0];
*td->val = td->ival * ratio * gps->runtime.multi_frame_falloff;
*td->val = td->ival * fabs(ratio) * gps->runtime.multi_frame_falloff;
CLAMP_MIN(*td->val, 0.001f);
}
}