diff options
author | Howard Trickey <howard.trickey@gmail.com> | 2019-01-07 15:29:54 +0300 |
---|---|---|
committer | Howard Trickey <howard.trickey@gmail.com> | 2019-01-07 15:29:54 +0300 |
commit | b786416106136ac5fd0b9ea55a0b0cf0c029243e (patch) | |
tree | 56edcc72aa8a30b1280c4a5a71dfce834fbe285f /source/blender/modifiers | |
parent | f19b3f9b77a54e12a083bde0a6036d7d60bb53e6 (diff) |
Fix T59151 Bevel modifier has bad input width for percent.
The units scaling was inappropriate when the bevel value was
to be interpreted as a percent, so added a separate rna property
for "Width Percent" and made UI show the width appropriate for
current offset_type.
Diffstat (limited to 'source/blender/modifiers')
-rw-r--r-- | source/blender/modifiers/intern/MOD_bevel.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/modifiers/intern/MOD_bevel.c b/source/blender/modifiers/intern/MOD_bevel.c index 363cdb083d4..6eee697a739 100644 --- a/source/blender/modifiers/intern/MOD_bevel.c +++ b/source/blender/modifiers/intern/MOD_bevel.c @@ -112,6 +112,7 @@ static Mesh *applyModifier(ModifierData *md, const ModifierEvalContext *ctx, Mes const bool vertex_only = (bmd->flags & MOD_BEVEL_VERT) != 0; const bool do_clamp = !(bmd->flags & MOD_BEVEL_OVERLAP_OK); const int offset_type = bmd->val_flags; + const float value = bmd->value; const int mat = CLAMPIS(bmd->mat, -1, ctx->object->totcol - 1); const bool loop_slide = (bmd->flags & MOD_BEVEL_EVEN_WIDTHS) == 0; const bool mark_seam = (bmd->edge_flags & MOD_BEVEL_MARK_SEAM); @@ -192,7 +193,7 @@ static Mesh *applyModifier(ModifierData *md, const ModifierEvalContext *ctx, Mes harden_normals = false; } - BM_mesh_bevel(bm, bmd->value, offset_type, bmd->res, bmd->profile, + BM_mesh_bevel(bm, value, offset_type, bmd->res, bmd->profile, vertex_only, bmd->lim_flags & MOD_BEVEL_WEIGHT, do_clamp, dvert, vgroup, mat, loop_slide, mark_seam, mark_sharp, harden_normals, face_strength_mode, mesh->smoothresh); |