Various RNA defaults for more consistency when updating settings (scene changes), and incorrect default values for scale settings.
This commit is contained in:
@@ -1443,6 +1443,7 @@ static void rna_def_object(BlenderRNA *brna)
|
||||
|
||||
static float default_quat[4] = {1,0,0,0}; /* default quaternion values */
|
||||
static float default_axisAngle[4] = {0,0,1,0}; /* default axis-angle rotation values */
|
||||
static float default_scale[3] = {1,1,1}; /* default scale values */
|
||||
int matrix_dimsize[]= {4, 4};
|
||||
int boundbox_dimsize[]= {8, 3};
|
||||
|
||||
@@ -1603,6 +1604,7 @@ static void rna_def_object(BlenderRNA *brna)
|
||||
prop= RNA_def_property(srna, "scale", PROP_FLOAT, PROP_XYZ);
|
||||
RNA_def_property_float_sdna(prop, NULL, "size");
|
||||
RNA_def_property_editable_array_func(prop, "rna_Object_scale_editable");
|
||||
RNA_def_property_float_array_default(prop, default_scale);
|
||||
RNA_def_property_ui_text(prop, "Scale", "Scaling of the object");
|
||||
RNA_def_property_update(prop, NC_OBJECT|ND_TRANSFORM, "rna_Object_update");
|
||||
|
||||
|
||||
@@ -663,6 +663,7 @@ static void rna_def_pose_channel(BlenderRNA *brna)
|
||||
|
||||
static float default_quat[4] = {1,0,0,0}; /* default quaternion values */
|
||||
static float default_axisAngle[4] = {0,0,1,0}; /* default axis-angle rotation values */
|
||||
static float default_scale[3] = {1,1,1}; /* default scale values */
|
||||
|
||||
StructRNA *srna;
|
||||
PropertyRNA *prop;
|
||||
@@ -722,6 +723,7 @@ static void rna_def_pose_channel(BlenderRNA *brna)
|
||||
prop= RNA_def_property(srna, "scale", PROP_FLOAT, PROP_XYZ);
|
||||
RNA_def_property_float_sdna(prop, NULL, "size");
|
||||
RNA_def_property_editable_array_func(prop, "rna_PoseChannel_scale_editable");
|
||||
RNA_def_property_float_array_default(prop, default_scale);
|
||||
RNA_def_property_ui_text(prop, "Scale", "");
|
||||
RNA_def_property_editable_func(prop, "rna_PoseChannel_proxy_editable"); // XXX... disabled, since proxy-locked layers are currently used for ensuring proxy-syncing too
|
||||
RNA_def_property_update(prop, NC_OBJECT|ND_POSE, "rna_Pose_update");
|
||||
|
||||
@@ -2696,7 +2696,7 @@ void RNA_def_scene(BlenderRNA *brna)
|
||||
RNA_def_property_int_funcs(prop, NULL, "rna_Scene_start_frame_set", NULL);
|
||||
RNA_def_property_range(prop, MINFRAME, MAXFRAME);
|
||||
RNA_def_property_ui_text(prop, "Start Frame", "First frame of the playback/rendering range");
|
||||
RNA_def_property_update(prop, NC_SCENE|ND_RENDER_OPTIONS, NULL);
|
||||
RNA_def_property_update(prop, NC_SCENE|ND_FRAME, NULL);
|
||||
|
||||
prop= RNA_def_property(srna, "end_frame", PROP_INT, PROP_TIME);
|
||||
RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
|
||||
@@ -2704,7 +2704,7 @@ void RNA_def_scene(BlenderRNA *brna)
|
||||
RNA_def_property_int_funcs(prop, NULL, "rna_Scene_end_frame_set", NULL);
|
||||
RNA_def_property_range(prop, MINFRAME, MAXFRAME);
|
||||
RNA_def_property_ui_text(prop, "End Frame", "Final frame of the playback/rendering range");
|
||||
RNA_def_property_update(prop, NC_SCENE|ND_RENDER_OPTIONS, NULL);
|
||||
RNA_def_property_update(prop, NC_SCENE|ND_FRAME, NULL);
|
||||
|
||||
prop= RNA_def_property(srna, "frame_step", PROP_INT, PROP_TIME);
|
||||
RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
|
||||
@@ -2712,7 +2712,7 @@ void RNA_def_scene(BlenderRNA *brna)
|
||||
RNA_def_property_range(prop, 0, MAXFRAME);
|
||||
RNA_def_property_ui_range(prop, 0, 100, 1, 0);
|
||||
RNA_def_property_ui_text(prop, "Frame Step", "Number of frames to skip forward while rendering/playing back each frame");
|
||||
RNA_def_property_update(prop, NC_SCENE|ND_RENDER_OPTIONS, NULL);
|
||||
RNA_def_property_update(prop, NC_SCENE|ND_FRAME, NULL);
|
||||
|
||||
/* Preview Range (frame-range for UI playback) */
|
||||
prop=RNA_def_property(srna, "use_preview_range", PROP_BOOLEAN, PROP_NONE);
|
||||
@@ -2720,21 +2720,21 @@ void RNA_def_scene(BlenderRNA *brna)
|
||||
RNA_def_property_boolean_sdna(prop, NULL, "r.flag", SCER_PRV_RANGE);
|
||||
RNA_def_property_boolean_funcs(prop, NULL, "rna_Scene_use_preview_range_set");
|
||||
RNA_def_property_ui_text(prop, "Use Preview Range", "");
|
||||
RNA_def_property_update(prop, NC_SCENE|ND_RENDER_OPTIONS, NULL);
|
||||
RNA_def_property_update(prop, NC_SCENE|ND_FRAME, NULL);
|
||||
|
||||
prop= RNA_def_property(srna, "preview_range_start_frame", PROP_INT, PROP_TIME);
|
||||
RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
|
||||
RNA_def_property_int_sdna(prop, NULL, "r.psfra");
|
||||
RNA_def_property_int_funcs(prop, NULL, "rna_Scene_preview_range_start_frame_set", NULL);
|
||||
RNA_def_property_ui_text(prop, "Preview Range Start Frame", "");
|
||||
RNA_def_property_update(prop, NC_SCENE|ND_RENDER_OPTIONS, NULL);
|
||||
RNA_def_property_update(prop, NC_SCENE|ND_FRAME, NULL);
|
||||
|
||||
prop= RNA_def_property(srna, "preview_range_end_frame", PROP_INT, PROP_TIME);
|
||||
RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
|
||||
RNA_def_property_int_sdna(prop, NULL, "r.pefra");
|
||||
RNA_def_property_int_funcs(prop, NULL, "rna_Scene_preview_range_end_frame_set", NULL);
|
||||
RNA_def_property_ui_text(prop, "Preview Range End Frame", "");
|
||||
RNA_def_property_update(prop, NC_SCENE|ND_RENDER_OPTIONS, NULL);
|
||||
RNA_def_property_update(prop, NC_SCENE|ND_FRAME, NULL);
|
||||
|
||||
/* Stamp */
|
||||
prop= RNA_def_property(srna, "stamp_note", PROP_STRING, PROP_NONE);
|
||||
|
||||
Reference in New Issue
Block a user