Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPablo Dobarro <pablodp606@gmail.com>2020-03-28 01:22:59 +0300
committerPablo Dobarro <pablodp606@gmail.com>2020-04-02 16:35:12 +0300
commit43f748a32fd541aac8cf499e03cf624806e30967 (patch)
tree63ac6e524c8d241a38d914a19078aa08c4cbf09e /source/blender/editors
parentb26bebd59f2d1a859f7faa2d57413448686da8a8 (diff)
Fix mesh boundary automask curve falloff
As the main use case of this feature is to work with cloth, using this curve makes more sense than a smoothstep to simulate cloth tension near the edges. Reviewed By: jbakker Differential Revision: https://developer.blender.org/D7262
Diffstat (limited to 'source/blender/editors')
-rw-r--r--source/blender/editors/sculpt_paint/sculpt.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c
index 82f9bbc5f56..73173571277 100644
--- a/source/blender/editors/sculpt_paint/sculpt.c
+++ b/source/blender/editors/sculpt_paint/sculpt.c
@@ -1741,7 +1741,7 @@ static float *sculpt_boundary_edges_automasking_init(Object *ob,
for (int i = 0; i < totvert; i++) {
if (edge_distance[i] != EDGE_DISTANCE_INF) {
const float p = 1.0f - ((float)edge_distance[i] / (float)propagation_steps);
- const float edge_boundary_automask = 3.0f * p * p - 2.0f * p * p * p;
+ const float edge_boundary_automask = pow2f(p);
automask_factor[i] *= (1.0f - edge_boundary_automask);
}
}