Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2010-09-02 11:00:34 +0400
committerCampbell Barton <ideasman42@gmail.com>2010-09-02 11:00:34 +0400
commitb2ae9d825c96ed73d2396b8da6e0c019a6384ff7 (patch)
tree267dcc85e082aeb9ca594d3ee752d19c84b5c72e /source/blender
parent35535c2cb9dce98dc9eb7dec7337cce40ad6d9d9 (diff)
- inconsistent rna names - use 'vertex_group_' as prefix, only ui scripts used this
- change curve offset to be 0.0 for its rest/default value (not 1.0)
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/blenkernel/intern/material.c2
-rw-r--r--source/blender/imbuf/intern/thumbs_blend.c2
-rw-r--r--source/blender/makesrna/intern/rna_cloth.c6
-rw-r--r--source/blender/makesrna/intern/rna_curve.c17
-rw-r--r--source/blender/makesrna/intern/rna_object_force.c6
-rw-r--r--source/blender/python/intern/bpy_array.c2
6 files changed, 24 insertions, 11 deletions
diff --git a/source/blender/blenkernel/intern/material.c b/source/blender/blenkernel/intern/material.c
index 9774e97f69b..e6cf0beb861 100644
--- a/source/blender/blenkernel/intern/material.c
+++ b/source/blender/blenkernel/intern/material.c
@@ -453,7 +453,7 @@ Material *give_current_material(Object *ob, int act)
}
else { /* in data */
- /* check for inconsistancy */
+ /* check for inconsistency */
if(*totcolp < ob->totcol)
ob->totcol= *totcolp;
if(act>ob->totcol) act= ob->totcol;
diff --git a/source/blender/imbuf/intern/thumbs_blend.c b/source/blender/imbuf/intern/thumbs_blend.c
index cb27b1a647f..2fef230f1c2 100644
--- a/source/blender/imbuf/intern/thumbs_blend.c
+++ b/source/blender/imbuf/intern/thumbs_blend.c
@@ -97,7 +97,7 @@ static ImBuf *loadblend_thumb(gzFile gzfile)
/* length */
bhead[1] -= sizeof(int) * 2;
- /* inconsistant image size, quit early */
+ /* inconsistent image size, quit early */
if(bhead[1] != size[0] * size[1] * sizeof(int))
return NULL;
diff --git a/source/blender/makesrna/intern/rna_cloth.c b/source/blender/makesrna/intern/rna_cloth.c
index e40bbcbbf50..71e95248512 100644
--- a/source/blender/makesrna/intern/rna_cloth.c
+++ b/source/blender/makesrna/intern/rna_cloth.c
@@ -253,7 +253,7 @@ static void rna_def_cloth_sim_settings(BlenderRNA *brna)
RNA_def_property_ui_text(prop, "Mass", "Mass of cloth material");
RNA_def_property_update(prop, 0, "rna_cloth_update");
- prop= RNA_def_property(srna, "mass_vertex_group", PROP_STRING, PROP_NONE);
+ prop= RNA_def_property(srna, "vertex_group_mass", PROP_STRING, PROP_NONE);
RNA_def_property_string_funcs(prop, "rna_ClothSettings_mass_vgroup_get", "rna_ClothSettings_mass_vgroup_length", "rna_ClothSettings_mass_vgroup_set");
RNA_def_property_ui_text(prop, "Mass Vertex Group", "Vertex Group for pinning of vertices");
RNA_def_property_update(prop, 0, "rna_cloth_update");
@@ -316,7 +316,7 @@ static void rna_def_cloth_sim_settings(BlenderRNA *brna)
RNA_def_property_ui_text(prop, "Structural Stiffness Maximum", "Maximum structural stiffness value");
RNA_def_property_update(prop, 0, "rna_cloth_update");
- prop= RNA_def_property(srna, "structural_stiffness_vertex_group", PROP_STRING, PROP_NONE);
+ prop= RNA_def_property(srna, "vertex_group_structural_stiffness", PROP_STRING, PROP_NONE);
RNA_def_property_string_funcs(prop, "rna_ClothSettings_struct_vgroup_get", "rna_ClothSettings_struct_vgroup_length", "rna_ClothSettings_struct_vgroup_set");
RNA_def_property_ui_text(prop, "Structural Stiffness Vertex Group", "Vertex group for fine control over structural stiffness");
RNA_def_property_update(prop, 0, "rna_cloth_update");
@@ -334,7 +334,7 @@ static void rna_def_cloth_sim_settings(BlenderRNA *brna)
RNA_def_property_ui_text(prop, "Bending Stiffness Maximum", "Maximum bending stiffness value");
RNA_def_property_update(prop, 0, "rna_cloth_update");
- prop= RNA_def_property(srna, "bending_vertex_group", PROP_STRING, PROP_NONE);
+ prop= RNA_def_property(srna, "vertex_group_bending", PROP_STRING, PROP_NONE);
RNA_def_property_string_funcs(prop, "rna_ClothSettings_bend_vgroup_get", "rna_ClothSettings_bend_vgroup_length", "rna_ClothSettings_bend_vgroup_set");
RNA_def_property_ui_text(prop, "Bending Stiffness Vertex Group", "Vertex group for fine control over bending stiffness");
RNA_def_property_update(prop, 0, "rna_cloth_update");
diff --git a/source/blender/makesrna/intern/rna_curve.c b/source/blender/makesrna/intern/rna_curve.c
index f5eace91831..fb6da576811 100644
--- a/source/blender/makesrna/intern/rna_curve.c
+++ b/source/blender/makesrna/intern/rna_curve.c
@@ -356,6 +356,18 @@ static void rna_Curve_resolution_v_update_data(Main *bmain, Scene *scene, Pointe
rna_Curve_update_data(bmain, scene, ptr);
}
+static float rna_Curve_offset_get(PointerRNA *ptr)
+{
+ Curve *cu= (Curve*)ptr->id.data;
+ return cu->width - 1.0f;
+}
+
+static void rna_Curve_offset_set(PointerRNA *ptr, float value)
+{
+ Curve *cu= (Curve*)ptr->id.data;
+ cu->width= 1.0f + value;
+}
+
/* name functions that ignore the first two ID characters */
void rna_Curve_body_get(PointerRNA *ptr, char *value)
{
@@ -1109,8 +1121,9 @@ static void rna_def_curve(BlenderRNA *brna)
prop= RNA_def_property(srna, "offset", PROP_FLOAT, PROP_NONE);
RNA_def_property_float_sdna(prop, NULL, "width");
- RNA_def_property_ui_range(prop, 0, 2.0, 0.1, 3);
- RNA_def_property_ui_text(prop, "Width", "Scale the original width (1.0) based on given factor");
+ RNA_def_property_ui_range(prop, -1.0, 1.0, 0.1, 3);
+ RNA_def_property_float_funcs(prop, "rna_Curve_offset_get", "rna_Curve_offset_set", NULL);
+ RNA_def_property_ui_text(prop, "Offset", "Offset the curve to adjust the width of a text");
RNA_def_property_update(prop, 0, "rna_Curve_update_data");
prop= RNA_def_property(srna, "extrude", PROP_FLOAT, PROP_NONE);
diff --git a/source/blender/makesrna/intern/rna_object_force.c b/source/blender/makesrna/intern/rna_object_force.c
index f019a96844d..3a8f66a3773 100644
--- a/source/blender/makesrna/intern/rna_object_force.c
+++ b/source/blender/makesrna/intern/rna_object_force.c
@@ -1474,7 +1474,7 @@ static void rna_def_softbody(BlenderRNA *brna)
RNA_def_property_ui_text(prop, "Mass", "General Mass value");
RNA_def_property_update(prop, 0, "rna_softbody_update");
- prop= RNA_def_property(srna, "mass_vertex_group", PROP_STRING, PROP_NONE);
+ prop= RNA_def_property(srna, "vertex_group_mass", PROP_STRING, PROP_NONE);
RNA_def_property_string_sdna(prop, NULL, "namedVG_Mass");
RNA_def_property_ui_text(prop, "Mass Vertex Group", "Control point mass values");
RNA_def_property_string_funcs(prop, NULL, NULL, "rna_SoftBodySettings_mass_vgroup_set");
@@ -1495,7 +1495,7 @@ static void rna_def_softbody(BlenderRNA *brna)
/* Goal */
- prop= RNA_def_property(srna, "goal_vertex_group", PROP_STRING, PROP_NONE);
+ prop= RNA_def_property(srna, "vertex_group_goal", PROP_STRING, PROP_NONE);
RNA_def_property_string_sdna(prop, NULL, "vertgroup");
RNA_def_property_clear_flag(prop, PROP_ANIMATABLE); /* not impossible .. but not supported yet */
RNA_def_property_string_funcs(prop, "rna_SoftBodySettings_goal_vgroup_get", "rna_SoftBodySettings_goal_vgroup_length", "rna_SoftBodySettings_goal_vgroup_set");
@@ -1581,7 +1581,7 @@ static void rna_def_softbody(BlenderRNA *brna)
RNA_def_property_range(prop, 0.0f, 1.0f);
RNA_def_property_ui_text(prop, "Shear", "Shear Stiffness");
- prop= RNA_def_property(srna, "spring_vertex_group", PROP_STRING, PROP_NONE);
+ prop= RNA_def_property(srna, "vertex_group_spring", PROP_STRING, PROP_NONE);
RNA_def_property_string_sdna(prop, NULL, "namedVG_Spring_K");
RNA_def_property_ui_text(prop, "Spring Vertex Group", "Control point spring strength values");
RNA_def_property_string_funcs(prop, NULL, NULL, "rna_SoftBodySettings_spring_vgroup_set");
diff --git a/source/blender/python/intern/bpy_array.c b/source/blender/python/intern/bpy_array.c
index 4420e61adae..1afd54b3607 100644
--- a/source/blender/python/intern/bpy_array.c
+++ b/source/blender/python/intern/bpy_array.c
@@ -496,7 +496,7 @@ PyObject *pyrna_py_from_array_index(BPy_PropertyArrayRNA *self, PointerRNA *ptr,
}
else {
index = arrayoffset + index;
- ret= (BPy_PropertyRNA*)pyrna_array_item(ptr, prop, index);
+ ret= (BPy_PropertyArrayRNA *)pyrna_array_item(ptr, prop, index);
}
return (PyObject*)ret;