From 2fe9e3c1f0fd968bb214e13763b58a35f637caa9 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Tue, 10 Feb 2015 03:00:37 +1100 Subject: more direct fix for last commit --- source/blender/editors/curve/editcurve_add.c | 5 ++--- source/blender/editors/mesh/editmesh_add.c | 5 ++--- 2 files changed, 4 insertions(+), 6 deletions(-) (limited to 'source/blender/editors') diff --git a/source/blender/editors/curve/editcurve_add.c b/source/blender/editors/curve/editcurve_add.c index 4e08ada9738..7c53896b969 100644 --- a/source/blender/editors/curve/editcurve_add.c +++ b/source/blender/editors/curve/editcurve_add.c @@ -479,7 +479,7 @@ static int curvesurf_prim_add(bContext *C, wmOperator *op, int type, int isSurf) unsigned int layer; float dia; float loc[3], rot[3]; - float mat[4][4], scale_mat[4][4]; + float mat[4][4]; WM_operator_view3d_unit_defaults(C, op); @@ -531,8 +531,7 @@ static int curvesurf_prim_add(bContext *C, wmOperator *op, int type, int isSurf) ED_object_new_primitive_matrix(C, obedit, loc, rot, mat); dia = RNA_float_get(op->ptr, "radius"); - scale_m4_fl(scale_mat, dia); - mul_m4_m4m4(mat, scale_mat, mat); + mul_mat3_m4_fl(mat, dia); nu = add_nurbs_primitive(C, obedit, mat, type, newob); editnurb = object_editcurve_get(obedit); diff --git a/source/blender/editors/mesh/editmesh_add.c b/source/blender/editors/mesh/editmesh_add.c index a2160df1e63..6ce5e8a304b 100644 --- a/source/blender/editors/mesh/editmesh_add.c +++ b/source/blender/editors/mesh/editmesh_add.c @@ -422,7 +422,7 @@ static int add_primitive_monkey_exec(bContext *C, wmOperator *op) { Object *obedit; BMEditMesh *em; - float mat[4][4], scale_mat[4][4]; + float mat[4][4]; float loc[3], rot[3]; float dia; bool enter_editmode; @@ -434,8 +434,7 @@ static int add_primitive_monkey_exec(bContext *C, wmOperator *op) obedit = make_prim_init(C, CTX_DATA_(BLF_I18NCONTEXT_ID_MESH, "Suzanne"), &dia, mat, &was_editmode, loc, rot, layer); dia = RNA_float_get(op->ptr, "radius"); - scale_m4_fl(scale_mat, dia); - mul_m4_m4m4(mat, scale_mat, mat); + mul_mat3_m4_fl(mat, dia); em = BKE_editmesh_from_object(obedit); -- cgit v1.2.3