diff options
author | Campbell Barton <ideasman42@gmail.com> | 2020-05-15 15:48:00 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2020-05-15 16:13:57 +0300 |
commit | fe0036c586d334a17a0b6bc008790749f58273be (patch) | |
tree | 7d687319527c12a2b284b4872771773e6a6841af /source/blender/blenkernel/intern/curve.c | |
parent | 0a32f6c8686c6a14a052f5b254655b3b69a581e3 (diff) |
Fix T76563: Transforming an auto-aligned point won't set it aligned
When local origins are used or a single control point is selected,
change the handle types from auto to aligned.
Diffstat (limited to 'source/blender/blenkernel/intern/curve.c')
-rw-r--r-- | source/blender/blenkernel/intern/curve.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/source/blender/blenkernel/intern/curve.c b/source/blender/blenkernel/intern/curve.c index b4a8625c0bb..d8fd405b6e5 100644 --- a/source/blender/blenkernel/intern/curve.c +++ b/source/blender/blenkernel/intern/curve.c @@ -4151,7 +4151,8 @@ void BKE_nurb_handle_calc_simple_auto(Nurb *nu, BezTriple *bezt) */ void BKE_nurb_bezt_handle_test(BezTriple *bezt, const eBezTriple_Flag__Alias sel_flag, - const bool use_handle) + const bool use_handle, + const bool use_around_local) { short flag = 0; @@ -4174,6 +4175,10 @@ void BKE_nurb_bezt_handle_test(BezTriple *bezt, flag = (bezt->f2 & sel_flag) ? (SEL_F1 | SEL_F2 | SEL_F3) : 0; } + if (use_around_local) { + flag &= ~SEL_F2; + } + /* check for partial selection */ if (!ELEM(flag, 0, SEL_F1 | SEL_F2 | SEL_F3)) { if (ELEM(bezt->h1, HD_AUTO, HD_AUTO_ANIM)) { @@ -4200,7 +4205,7 @@ void BKE_nurb_bezt_handle_test(BezTriple *bezt, #undef SEL_F3 } -void BKE_nurb_handles_test(Nurb *nu, const bool use_handle) +void BKE_nurb_handles_test(Nurb *nu, const bool use_handle, const bool use_around_local) { BezTriple *bezt; int a; @@ -4212,7 +4217,7 @@ void BKE_nurb_handles_test(Nurb *nu, const bool use_handle) bezt = nu->bezt; a = nu->pntsu; while (a--) { - BKE_nurb_bezt_handle_test(bezt, SELECT, use_handle); + BKE_nurb_bezt_handle_test(bezt, SELECT, use_handle, use_around_local); bezt++; } |