diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-02-11 14:56:21 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-02-11 14:56:21 +0400 |
commit | 3a192ca3591d0ed5a6356f791c86cbd2a3d0209a (patch) | |
tree | a3fa776da8d43d4d058984b9f863b72a880f384f /source/blender/editors/object/object_transform.c | |
parent | c1ca09b8c80a4fc063f7b804f68cd5c86db9f517 (diff) |
patch [#33697] Apply transformation added to metaballs.
from Jesse Werner (vidjogamer), with own addition of RNA function, scale and rotation support.
Diffstat (limited to 'source/blender/editors/object/object_transform.c')
-rw-r--r-- | source/blender/editors/object/object_transform.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/source/blender/editors/object/object_transform.c b/source/blender/editors/object/object_transform.c index 68075e7b6f9..9dd34623739 100644 --- a/source/blender/editors/object/object_transform.c +++ b/source/blender/editors/object/object_transform.c @@ -67,6 +67,7 @@ #include "ED_armature.h" #include "ED_keyframing.h" +#include "ED_mball.h" #include "ED_mesh.h" #include "ED_screen.h" #include "ED_view3d.h" @@ -407,6 +408,12 @@ static int apply_objects_internal(bContext *C, ReportList *reports, int apply_lo change = 0; } } + else if (ob->type == OB_MBALL) { + if (ID_REAL_USERS(ob->data) > 1) { + BKE_report(reports, RPT_ERROR, "Cannot apply to a multi user metaball, doing nothing"); + change = 0; + } + } else if (ELEM(ob->type, OB_CURVE, OB_SURF)) { Curve *cu; @@ -516,6 +523,10 @@ static int apply_objects_internal(bContext *C, ReportList *reports, int apply_lo bp++; } } + else if (ob->type == OB_MBALL) { + MetaBall *mb = ob->data; + ED_mball_transform(mb, (float *)mat); + } else if (ELEM(ob->type, OB_CURVE, OB_SURF)) { Curve *cu = ob->data; |