diff options
author | Nicholas Bishop <nicholasbishop@gmail.com> | 2009-01-02 04:28:02 +0300 |
---|---|---|
committer | Nicholas Bishop <nicholasbishop@gmail.com> | 2009-01-02 04:28:02 +0300 |
commit | f4a4279611938c8e4003a8a112584ece0fd25665 (patch) | |
tree | 1736bb731e102d3b6e50b8e4b6f8738ac4d23629 /source | |
parent | e6838f621d4d97e12853d7ad20610595582f50d8 (diff) |
Added RNA for Armature modifier
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/makesrna/intern/rna_modifier.c | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/source/blender/makesrna/intern/rna_modifier.c b/source/blender/makesrna/intern/rna_modifier.c index 1b085c9fee3..05fa8dd134c 100644 --- a/source/blender/makesrna/intern/rna_modifier.c +++ b/source/blender/makesrna/intern/rna_modifier.c @@ -29,6 +29,7 @@ #include "rna_internal.h" +#include "DNA_armature_types.h" #include "DNA_modifier_types.h" #include "DNA_scene_types.h" @@ -403,10 +404,40 @@ static void rna_def_modifier_wave(BlenderRNA *brna) static void rna_def_modifier_armature(BlenderRNA *brna) { StructRNA *srna; + PropertyRNA *prop; srna= RNA_def_struct(brna, "ArmatureModifier", "Modifier"); RNA_def_struct_ui_text(srna, "Armature Modifier", "Armature Modifier."); RNA_def_struct_sdna(srna, "ArmatureModifierData"); + + prop= RNA_def_property(srna, "armature", PROP_POINTER, PROP_NONE); + RNA_def_property_pointer_sdna(prop, NULL, "object"); + RNA_def_property_struct_type(prop, "ID"); + RNA_def_property_ui_text(prop, "Armature", "Armature object to deform with."); + + prop= RNA_def_property(srna, "vertex_group", PROP_STRING, PROP_NONE); + RNA_def_property_string_sdna(prop, NULL, "defgrp_name"); + RNA_def_property_ui_text(prop, "Vertex Group", "Vertex group name."); + + prop= RNA_def_property(srna, "invert", PROP_BOOLEAN, PROP_NONE); + RNA_def_property_boolean_sdna(prop, NULL, "deformflag", ARM_DEF_INVERT_VGROUP); + RNA_def_property_ui_text(prop, "Invert", "Invert vertex group influence."); + + prop= RNA_def_property(srna, "use_vertex_groups", PROP_BOOLEAN, PROP_NONE); + RNA_def_property_boolean_sdna(prop, NULL, "deformflag", ARM_DEF_VGROUP); + RNA_def_property_ui_text(prop, "Use Vertex Groups", ""); + + prop= RNA_def_property(srna, "use_bone_envelopes", PROP_BOOLEAN, PROP_NONE); + RNA_def_property_boolean_sdna(prop, NULL, "deformflag", ARM_DEF_ENVELOPE); + RNA_def_property_ui_text(prop, "Use Bone Envelopes", ""); + + prop= RNA_def_property(srna, "quaternion", PROP_BOOLEAN, PROP_NONE); + RNA_def_property_boolean_sdna(prop, NULL, "deformflag", ARM_DEF_QUATERNION); + RNA_def_property_ui_text(prop, "Quaternion", "Deform rotation interpolation with quaternions."); + + prop= RNA_def_property(srna, "b_bone_rest", PROP_BOOLEAN, PROP_NONE); + RNA_def_property_boolean_sdna(prop, NULL, "deformflag", ARM_DEF_B_BONE_REST); + RNA_def_property_ui_text(prop, "Quaternion", "Make B-Bones deform already in rest position"); } static void rna_def_modifier_hook(BlenderRNA *brna) |