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-09-10 23:07:28 +0300
committerPablo Dobarro <pablodp606@gmail.com>2020-09-10 23:07:43 +0300
commitc01f8bb672f3d7140f5a6df80c0279e07c4b328b (patch)
tree1279d22688dda2c4831c4b74b22e3cdf9826e66b /source/blender/editors/sculpt_paint
parent2ea2ec023ddcff4b593ff8179c96e56f166b032f (diff)
Sculpt: Enable pen pressure for Scrape/Fill Area Radius
This should improve the issue with Scrape accumulation in concave surfaces. When the strength of the brush is higher, the area radius is also bigger, so the scrape plane is more stable preventing it from accumulating displacement in the same area. The Scrape/Fill default presets are also updated to include this functionality. Reviewed By: sergey Differential Revision: https://developer.blender.org/D8821
Diffstat (limited to 'source/blender/editors/sculpt_paint')
-rw-r--r--source/blender/editors/sculpt_paint/sculpt.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c
index 5070709cb6d..e6ea79a771a 100644
--- a/source/blender/editors/sculpt_paint/sculpt.c
+++ b/source/blender/editors/sculpt_paint/sculpt.c
@@ -1920,6 +1920,9 @@ static void calc_area_normal_and_center_task_cb(void *__restrict userdata,
if (ELEM(data->brush->sculpt_tool, SCULPT_TOOL_SCRAPE, SCULPT_TOOL_FILL) &&
data->brush->area_radius_factor > 0.0f) {
test_radius *= data->brush->area_radius_factor;
+ if (ss->cache && data->brush->flag2 & BRUSH_AREA_RADIUS_PRESSURE) {
+ test_radius *= ss->cache->pressure;
+ }
}
else {
test_radius *= data->brush->normal_radius_factor;