Changeset View
Changeset View
Standalone View
Standalone View
source/blender/makesrna/intern/rna_rigidbody.c
| Show First 20 Lines • Show All 900 Lines • ▼ Show 20 Lines | static void rna_def_rigidbody_world(BlenderRNA *brna) | ||||
| RNA_def_property_float_sdna(prop, NULL, "time_scale"); | RNA_def_property_float_sdna(prop, NULL, "time_scale"); | ||||
| RNA_def_property_range(prop, 0.0f, 100.0f); | RNA_def_property_range(prop, 0.0f, 100.0f); | ||||
| RNA_def_property_ui_range(prop, 0.0f, 10.0f, 1, 3); | RNA_def_property_ui_range(prop, 0.0f, 10.0f, 1, 3); | ||||
| RNA_def_property_float_default(prop, 1.0f); | RNA_def_property_float_default(prop, 1.0f); | ||||
| RNA_def_property_ui_text(prop, "Time Scale", "Change the speed of the simulation"); | RNA_def_property_ui_text(prop, "Time Scale", "Change the speed of the simulation"); | ||||
| RNA_def_property_update(prop, NC_SCENE, "rna_RigidBodyWorld_reset"); | RNA_def_property_update(prop, NC_SCENE, "rna_RigidBodyWorld_reset"); | ||||
| /* timestep */ | /* timestep */ | ||||
| prop = RNA_def_property(srna, "steps_per_second", PROP_INT, PROP_NONE); | prop = RNA_def_property(srna, "substeps_per_frame", PROP_INT, PROP_NONE); | ||||
| RNA_def_property_int_sdna(prop, NULL, "steps_per_second"); | RNA_def_property_int_sdna(prop, NULL, "substeps_per_frame"); | ||||
| RNA_def_property_range(prop, 1, SHRT_MAX); | RNA_def_property_range(prop, 1, SHRT_MAX); | ||||
| RNA_def_property_ui_range(prop, 60, 1000, 1, -1); | RNA_def_property_ui_range(prop, 1, 1000, 1, -1); | ||||
| RNA_def_property_int_default(prop, 60); | RNA_def_property_int_default(prop, 10); | ||||
| RNA_def_property_ui_text( | RNA_def_property_ui_text( | ||||
| prop, | prop, | ||||
| "Steps Per Second", | "Substeps Per Frame", | ||||
| "Number of simulation steps taken per second (higher values are more accurate " | "Number of simulation steps taken per frame (higher values are more accurate " | ||||
| "but slower)"); | "but slower)"); | ||||
| RNA_def_property_update(prop, NC_SCENE, "rna_RigidBodyWorld_reset"); | RNA_def_property_update(prop, NC_SCENE, "rna_RigidBodyWorld_reset"); | ||||
| /* constraint solver iterations */ | /* constraint solver iterations */ | ||||
| prop = RNA_def_property(srna, "solver_iterations", PROP_INT, PROP_NONE); | prop = RNA_def_property(srna, "solver_iterations", PROP_INT, PROP_NONE); | ||||
| RNA_def_property_int_sdna(prop, NULL, "num_solver_iterations"); | RNA_def_property_int_sdna(prop, NULL, "num_solver_iterations"); | ||||
| RNA_def_property_range(prop, 1, 1000); | RNA_def_property_range(prop, 1, 1000); | ||||
| RNA_def_property_ui_range(prop, 10, 100, 1, -1); | RNA_def_property_ui_range(prop, 10, 100, 1, -1); | ||||
| ▲ Show 20 Lines • Show All 671 Lines • Show Last 20 Lines | |||||