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:
authorGaia Clary <gaia.clary@machinimatrix.org>2016-05-26 19:22:36 +0300
committerGaia Clary <gaia.clary@machinimatrix.org>2016-05-26 19:22:36 +0300
commit1346482d23f167fa57049128384246397fda8d27 (patch)
tree89addd5cd73c1edd47cde5022ce8724421998964 /source/blender/collada/ArmatureExporter.cpp
parent29aa13cfa284182ee47818a477a3b8b7297a12c8 (diff)
moved is_leaf_bone() to collada utils for reuse in exporter and importer
Diffstat (limited to 'source/blender/collada/ArmatureExporter.cpp')
-rw-r--r--source/blender/collada/ArmatureExporter.cpp12
1 files changed, 1 insertions, 11 deletions
diff --git a/source/blender/collada/ArmatureExporter.cpp b/source/blender/collada/ArmatureExporter.cpp
index cf02293886c..47a0ffda3c6 100644
--- a/source/blender/collada/ArmatureExporter.cpp
+++ b/source/blender/collada/ArmatureExporter.cpp
@@ -150,16 +150,6 @@ std::string ArmatureExporter::get_joint_sid(Bone *bone, Object *ob_arm)
return get_joint_id(bone, ob_arm);
}
-static bool is_leaf_bone(Bone *bone)
-{
- for (Bone *child = (Bone *)bone->childbase.first; child; child = child->next) {
- if (child->flag & BONE_CONNECTED) {
- return false;
- }
- }
- return true;
-}
-
// parent_mat is armature-space
void ArmatureExporter::add_bone_node(Bone *bone, Object *ob_arm, Scene *sce,
SceneExporter *se,
@@ -185,7 +175,7 @@ void ArmatureExporter::add_bone_node(Bone *bone, Object *ob_arm, Scene *sce,
}
}
- if (is_leaf_bone(bone))
+ if (bc_is_leaf_bone(bone))
{
node.addExtraTechniqueParameter("blender", "tip_x", bone->arm_tail[0] - bone->arm_head[0]);
node.addExtraTechniqueParameter("blender", "tip_y", bone->arm_tail[1] - bone->arm_head[1]);