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-08-18 17:13:43 +0300
committerPablo Dobarro <pablodp606@gmail.com>2020-08-18 17:14:10 +0300
commit3e5431fdf43906cd900f960f65ef8897e8a108a3 (patch)
treee750ab789a8309eefcc566a7848791ff7ac12428 /source/blender/editors/sculpt_paint/sculpt.c
parent872efd8d73a3820680379230d83a0aadf5fc29ca (diff)
Sculpt: Invert Smooth to Enhance Details
This enables the invert mode in the smooth brush as Enhance Details. The operation is similar to the Sharpen Filter intensify details parameter, which consist in applying the laplacian smooth displacement in the opposite direction calculated using the original coordinates. Reviewed By: sergey Differential Revision: https://developer.blender.org/D8509
Diffstat (limited to 'source/blender/editors/sculpt_paint/sculpt.c')
-rw-r--r--source/blender/editors/sculpt_paint/sculpt.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c
index 03d079ba0e1..5d09109c506 100644
--- a/source/blender/editors/sculpt_paint/sculpt.c
+++ b/source/blender/editors/sculpt_paint/sculpt.c
@@ -2331,7 +2331,7 @@ static float brush_strength(const Sculpt *sd,
}
case SCULPT_TOOL_SMOOTH:
- return alpha * pressure * feather;
+ return flip * alpha * pressure * feather;
case SCULPT_TOOL_PINCH:
if (flip > 0.0f) {
@@ -6365,6 +6365,7 @@ void SCULPT_cache_free(StrokeCache *cache)
MEM_SAFE_FREE(cache->surface_smooth_laplacian_disp);
MEM_SAFE_FREE(cache->layer_displacement_factor);
MEM_SAFE_FREE(cache->prev_colors);
+ MEM_SAFE_FREE(cache->detail_directions);
if (cache->pose_ik_chain) {
SCULPT_pose_ik_chain_free(cache->pose_ik_chain);