[Bf-blender-cvs] [5e13097dc3a] master: Fix T53145: bevel tool fails when used a second time.
Brecht Van Lommel
noreply at git.blender.org
Thu Nov 23 20:21:02 CET 2017
Commit: 5e13097dc3a3463d6b8643a5ace673d7a462c934
Author: Brecht Van Lommel
Date: Thu Nov 23 20:14:31 2017 +0100
Branches: master
https://developer.blender.org/rB5e13097dc3a3463d6b8643a5ace673d7a462c934
Fix T53145: bevel tool fails when used a second time.
Pixel size was not initial early enough. For first time this was not a problem
because the bevel amount starts at 0 then, and after the mouse moves the pixel
size is initialized. For the second time the bevel amount starts at a non-zero
value, and it failed then.
===================================================================
M source/blender/editors/mesh/editmesh_bevel.c
===================================================================
diff --git a/source/blender/editors/mesh/editmesh_bevel.c b/source/blender/editors/mesh/editmesh_bevel.c
index 2af05a9ad8d..e541df8ffa3 100644
--- a/source/blender/editors/mesh/editmesh_bevel.c
+++ b/source/blender/editors/mesh/editmesh_bevel.c
@@ -335,11 +335,12 @@ static int edbm_bevel_invoke(bContext *C, wmOperator *op, const wmEvent *event)
* ideally this will never happen and should be checked for above */
opdata->mcenter[0] = opdata->mcenter[1] = 0;
}
- edbm_bevel_calc_initial_length(op, event, false);
/* for OFFSET_VALUE only, the scale is the size of a pixel under the mouse in 3d space */
opdata->scale[OFFSET_VALUE] = rv3d ? ED_view3d_pixel_size(rv3d, center_3d) : 1.0f;
+ edbm_bevel_calc_initial_length(op, event, false);
+
edbm_bevel_update_header(C, op);
if (!edbm_bevel_calc(op)) {
More information about the Bf-blender-cvs
mailing list