Changeset View
Changeset View
Standalone View
Standalone View
source/blender/makesrna/intern/rna_constraint.c
| Show First 20 Lines • Show All 553 Lines • ▼ Show 20 Lines | |||||
| static void rna_def_constraint_childof(BlenderRNA *brna) | static void rna_def_constraint_childof(BlenderRNA *brna) | ||||
| { | { | ||||
| StructRNA *srna; | StructRNA *srna; | ||||
| PropertyRNA *prop; | PropertyRNA *prop; | ||||
| srna = RNA_def_struct(brna, "ChildOfConstraint", "Constraint"); | srna = RNA_def_struct(brna, "ChildOfConstraint", "Constraint"); | ||||
| RNA_def_struct_ui_text(srna, "Child Of Constraint", "Create constraint-based parent-child relationship"); | RNA_def_struct_ui_text(srna, "Child Of Constraint", "Create constraint-based parent-child relationship"); | ||||
| rna_def_constraint_headtail_common(srna); | |||||
| RNA_def_struct_sdna_from(srna, "bChildOfConstraint", "data"); | RNA_def_struct_sdna_from(srna, "bChildOfConstraint", "data"); | ||||
| rna_def_constraint_target_common(srna); | rna_def_constraint_target_common(srna); | ||||
| prop = RNA_def_property(srna, "use_location_x", PROP_BOOLEAN, PROP_NONE); | prop = RNA_def_property(srna, "use_location_x", PROP_BOOLEAN, PROP_NONE); | ||||
| RNA_def_property_boolean_sdna(prop, NULL, "flag", CHILDOF_LOCX); | RNA_def_property_boolean_sdna(prop, NULL, "flag", CHILDOF_LOCX); | ||||
| RNA_def_property_ui_text(prop, "Location X", "Use X Location of Parent"); | RNA_def_property_ui_text(prop, "Location X", "Use X Location of Parent"); | ||||
| RNA_def_property_update(prop, NC_OBJECT | ND_CONSTRAINT, "rna_Constraint_update"); | RNA_def_property_update(prop, NC_OBJECT | ND_CONSTRAINT, "rna_Constraint_update"); | ||||
| ▲ Show 20 Lines • Show All 321 Lines • ▼ Show 20 Lines | |||||
| static void rna_def_constraint_rotate_like(BlenderRNA *brna) | static void rna_def_constraint_rotate_like(BlenderRNA *brna) | ||||
| { | { | ||||
| StructRNA *srna; | StructRNA *srna; | ||||
| PropertyRNA *prop; | PropertyRNA *prop; | ||||
| srna = RNA_def_struct(brna, "CopyRotationConstraint", "Constraint"); | srna = RNA_def_struct(brna, "CopyRotationConstraint", "Constraint"); | ||||
| RNA_def_struct_ui_text(srna, "Copy Rotation Constraint", "Copy the rotation of the target"); | RNA_def_struct_ui_text(srna, "Copy Rotation Constraint", "Copy the rotation of the target"); | ||||
| rna_def_constraint_headtail_common(srna); | |||||
| RNA_def_struct_sdna_from(srna, "bRotateLikeConstraint", "data"); | RNA_def_struct_sdna_from(srna, "bRotateLikeConstraint", "data"); | ||||
| rna_def_constraint_target_common(srna); | rna_def_constraint_target_common(srna); | ||||
| prop = RNA_def_property(srna, "use_x", PROP_BOOLEAN, PROP_NONE); | prop = RNA_def_property(srna, "use_x", PROP_BOOLEAN, PROP_NONE); | ||||
| RNA_def_property_boolean_sdna(prop, NULL, "flag", ROTLIKE_X); | RNA_def_property_boolean_sdna(prop, NULL, "flag", ROTLIKE_X); | ||||
| RNA_def_property_ui_text(prop, "Copy X", "Copy the target's X rotation"); | RNA_def_property_ui_text(prop, "Copy X", "Copy the target's X rotation"); | ||||
| RNA_def_property_update(prop, NC_OBJECT | ND_CONSTRAINT, "rna_Constraint_update"); | RNA_def_property_update(prop, NC_OBJECT | ND_CONSTRAINT, "rna_Constraint_update"); | ||||
| Show All 31 Lines | |||||
| static void rna_def_constraint_size_like(BlenderRNA *brna) | static void rna_def_constraint_size_like(BlenderRNA *brna) | ||||
| { | { | ||||
| StructRNA *srna; | StructRNA *srna; | ||||
| PropertyRNA *prop; | PropertyRNA *prop; | ||||
| srna = RNA_def_struct(brna, "CopyScaleConstraint", "Constraint"); | srna = RNA_def_struct(brna, "CopyScaleConstraint", "Constraint"); | ||||
| RNA_def_struct_ui_text(srna, "Copy Scale Constraint", "Copy the scale of the target"); | RNA_def_struct_ui_text(srna, "Copy Scale Constraint", "Copy the scale of the target"); | ||||
| rna_def_constraint_headtail_common(srna); | |||||
| RNA_def_struct_sdna_from(srna, "bSizeLikeConstraint", "data"); | RNA_def_struct_sdna_from(srna, "bSizeLikeConstraint", "data"); | ||||
| rna_def_constraint_target_common(srna); | rna_def_constraint_target_common(srna); | ||||
| prop = RNA_def_property(srna, "use_x", PROP_BOOLEAN, PROP_NONE); | prop = RNA_def_property(srna, "use_x", PROP_BOOLEAN, PROP_NONE); | ||||
| RNA_def_property_boolean_sdna(prop, NULL, "flag", SIZELIKE_X); | RNA_def_property_boolean_sdna(prop, NULL, "flag", SIZELIKE_X); | ||||
| RNA_def_property_ui_text(prop, "Copy X", "Copy the target's X scale"); | RNA_def_property_ui_text(prop, "Copy X", "Copy the target's X scale"); | ||||
| RNA_def_property_update(prop, NC_OBJECT | ND_CONSTRAINT, "rna_Constraint_update"); | RNA_def_property_update(prop, NC_OBJECT | ND_CONSTRAINT, "rna_Constraint_update"); | ||||
| ▲ Show 20 Lines • Show All 1,663 Lines • Show Last 20 Lines | |||||