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>2014-09-01 14:09:31 +0400
committerCampbell Barton <ideasman42@gmail.com>2014-09-01 15:01:11 +0400
commite8f3fa99de8196a36736381b03015689492137bd (patch)
treef02e6a039cf55792053999a41220fbcbc8eaec59 /source/blender/editors/armature
parentd91916725d0d20f95c6d4c069428bd1076680087 (diff)
Support more object types scene-scale (on creation)
- lamp - camera - font - empty & effector Also fix inconsistency with apply transform (modified shape-keys for meshes but not curve/lattice)
Diffstat (limited to 'source/blender/editors/armature')
-rw-r--r--source/blender/editors/armature/armature_add.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/source/blender/editors/armature/armature_add.c b/source/blender/editors/armature/armature_add.c
index 16975eed75e..eba1bc4d78d 100644
--- a/source/blender/editors/armature/armature_add.c
+++ b/source/blender/editors/armature/armature_add.c
@@ -84,7 +84,7 @@ EditBone *ED_armature_edit_bone_add(bArmature *arm, const char *name)
return bone;
}
-void add_primitive_bone(Object *obedit_arm, bool view_aligned)
+EditBone *ED_armature_edit_bone_add_primitive(Object *obedit_arm, float length, bool view_aligned)
{
bArmature *arm = obedit_arm->data;
EditBone *bone;
@@ -99,10 +99,9 @@ void add_primitive_bone(Object *obedit_arm, bool view_aligned)
zero_v3(bone->head);
zero_v3(bone->tail);
- if (view_aligned)
- bone->tail[1] = 1.0f;
- else
- bone->tail[2] = 1.0f;
+ bone->tail[view_aligned ? 1 : 2] = length;
+
+ return bone;
}