From 850f9452a477dda876bafbb54cea9a3a9f39cd54 Mon Sep 17 00:00:00 2001 From: Pablo Dobarro Date: Fri, 6 Nov 2020 02:15:36 +0100 Subject: Fix wrong DNA flag for hide face sets It was using the same flag as SCULPT_DYNTOPO_DETAIL_MANUAL Reviewed By: sergey Differential Revision: https://developer.blender.org/D9484 --- source/blender/makesdna/DNA_scene_types.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/blender/makesdna/DNA_scene_types.h b/source/blender/makesdna/DNA_scene_types.h index 2449608be4c..af499b0684b 100644 --- a/source/blender/makesdna/DNA_scene_types.h +++ b/source/blender/makesdna/DNA_scene_types.h @@ -2203,7 +2203,7 @@ typedef enum eSculptFlags { SCULPT_HIDE_MASK = (1 << 15), /* Don't display face sets in viewport. */ - SCULPT_HIDE_FACE_SETS = (1 << 16), + SCULPT_HIDE_FACE_SETS = (1 << 17), } eSculptFlags; /* ImagePaintSettings.mode */ -- cgit v1.2.3 From f923b6faa9f44ba94aee33dfc656b8341ca548c1 Mon Sep 17 00:00:00 2001 From: Pablo Dobarro Date: Mon, 2 Nov 2020 23:02:02 +0100 Subject: Fix assert in the sculpt pen tilt code Reviewed By: campbellbarton Differential Revision: https://developer.blender.org/D9422 --- source/blender/editors/sculpt_paint/sculpt.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c index 875f24837c1..8c03d147768 100644 --- a/source/blender/editors/sculpt_paint/sculpt.c +++ b/source/blender/editors/sculpt_paint/sculpt.c @@ -2819,9 +2819,12 @@ void SCULPT_tilt_apply_to_normal(float r_normal[3], StrokeCache *cache, const fl } const float rot_max = M_PI_2 * tilt_strength * SCULPT_TILT_SENSITIVITY; mul_v3_mat3_m4v3(r_normal, cache->vc->obact->obmat, r_normal); - rotate_v3_v3v3fl(r_normal, r_normal, cache->vc->rv3d->viewinv[0], cache->y_tilt * rot_max); - rotate_v3_v3v3fl(r_normal, r_normal, cache->vc->rv3d->viewinv[1], cache->x_tilt * rot_max); - mul_v3_mat3_m4v3(r_normal, cache->vc->obact->imat, r_normal); + float normal_tilt_y[3]; + rotate_v3_v3v3fl(normal_tilt_y, r_normal, cache->vc->rv3d->viewinv[0], cache->y_tilt * rot_max); + float normal_tilt_xy[3]; + rotate_v3_v3v3fl( + normal_tilt_xy, normal_tilt_y, cache->vc->rv3d->viewinv[1], cache->x_tilt * rot_max); + mul_v3_mat3_m4v3(r_normal, cache->vc->obact->imat, normal_tilt_xy); normalize_v3(r_normal); } -- cgit v1.2.3