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:
Diffstat (limited to 'source/blender/editors/sculpt_paint/sculpt.c')
-rw-r--r--source/blender/editors/sculpt_paint/sculpt.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c
index be985342ea8..2ee49f71a78 100644
--- a/source/blender/editors/sculpt_paint/sculpt.c
+++ b/source/blender/editors/sculpt_paint/sculpt.c
@@ -2979,7 +2979,7 @@ static void sculpt_update_brush_delta(Sculpt *sd, Object *ob, Brush *brush)
SCULPT_TOOL_GRAB, SCULPT_TOOL_NUDGE,
SCULPT_TOOL_CLAY_TUBES, SCULPT_TOOL_SNAKE_HOOK,
SCULPT_TOOL_THUMB)) {
- float grab_location[3], imat[4][4], delta[3];
+ float grab_location[3], imat[4][4], delta[3], loc[3];
if(cache->first_time) {
copy_v3_v3(cache->orig_grab_location,
@@ -2989,10 +2989,8 @@ static void sculpt_update_brush_delta(Sculpt *sd, Object *ob, Brush *brush)
add_v3_v3(cache->true_location, cache->grab_delta);
/* compute 3d coordinate at same z from original location + mouse */
- initgrabz(cache->vc->rv3d,
- cache->orig_grab_location[0],
- cache->orig_grab_location[1],
- cache->orig_grab_location[2]);
+ mul_v3_m4v3(loc, ob->obmat, cache->orig_grab_location);
+ initgrabz(cache->vc->rv3d, loc[0], loc[1], loc[2]);
ED_view3d_win_to_delta(cache->vc->ar, cache->mouse, grab_location);
@@ -3088,9 +3086,6 @@ static void sculpt_update_cache_variants(bContext *C, Sculpt *sd, Object *ob, st
else {
cache->initial_radius= brush_unprojected_radius(brush);
}
-
- if (ELEM(brush->sculpt_tool, SCULPT_TOOL_GRAB, SCULPT_TOOL_SNAKE_HOOK))
- cache->initial_radius *= 2.0f;
}
if(brush_use_size_pressure(brush)) {