diff options
author | Bastien Montagne <montagne29@wanadoo.fr> | 2018-06-06 16:50:24 +0300 |
---|---|---|
committer | Bastien Montagne <montagne29@wanadoo.fr> | 2018-06-07 12:11:46 +0300 |
commit | 54f9cd52835bdd96cdd01cf643cfccf8a229c04b (patch) | |
tree | 95095d556c91743b9012387726fbdccc61f38c00 /source/blender/makesrna | |
parent | 409cfba1a3cdec228c7f93aa8c1fbc912a6d6525 (diff) |
Cleanup: Nuke moar G.main usages...
Diffstat (limited to 'source/blender/makesrna')
-rw-r--r-- | source/blender/makesrna/intern/rna_armature.c | 5 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_object.c | 2 |
2 files changed, 4 insertions, 3 deletions
diff --git a/source/blender/makesrna/intern/rna_armature.c b/source/blender/makesrna/intern/rna_armature.c index 7feca708fe8..b2bca9b6c3a 100644 --- a/source/blender/makesrna/intern/rna_armature.c +++ b/source/blender/makesrna/intern/rna_armature.c @@ -478,9 +478,9 @@ static int rna_Armature_is_editmode_get(PointerRNA *ptr) return (arm->edbo != NULL); } -static void rna_Armature_transform(struct bArmature *arm, float *mat) +static void rna_Armature_transform(struct bArmature *arm, Main *bmain, float *mat) { - ED_armature_transform(arm, (float (*)[4])mat, true); + ED_armature_transform(bmain, arm, (float (*)[4])mat, true); } #else @@ -1011,6 +1011,7 @@ static void rna_def_armature(BlenderRNA *brna) RNA_def_struct_sdna(srna, "bArmature"); func = RNA_def_function(srna, "transform", "rna_Armature_transform"); + RNA_def_function_flag(func, FUNC_USE_MAIN); RNA_def_function_ui_description(func, "Transform armature bones by a matrix"); parm = RNA_def_float_matrix(func, "matrix", 4, 4, NULL, 0.0f, 0.0f, "", "Matrix", 0.0f, 0.0f); RNA_def_parameter_flags(parm, 0, PARM_REQUIRED); diff --git a/source/blender/makesrna/intern/rna_object.c b/source/blender/makesrna/intern/rna_object.c index f3ff88c3200..6939f7d59a1 100644 --- a/source/blender/makesrna/intern/rna_object.c +++ b/source/blender/makesrna/intern/rna_object.c @@ -283,7 +283,7 @@ static void rna_Object_active_shape_update(Main *bmain, Scene *scene, PointerRNA break; case OB_CURVE: case OB_SURF: - ED_curve_editnurb_load(ob); + ED_curve_editnurb_load(bmain, ob); ED_curve_editnurb_make(ob); break; case OB_LATTICE: |