Provided updated scripts are NOT OFFICIAL bug fixes. Use at your own risk!
2009.08.11 by dynabyte ( cast3d@gmail.com,
www.cast3d.org):
- Fixed skeleton/bone and animation. (export only). Brief change log:
Fuction Controller.SaveToDae :
INV_BIND_MATRIX composition as = (bArmatureObject.matrixWorld * Bone.matrix['ARMATURESPACE']).invert()
Fuction ArmatrureNode.SaveToDae :
mutliple root bones handling added
return argument as list
Fuction ArmatrureNode.BoneToDae :
local bone matrix composition as = Bone.matrix['ARMATURESPACE'] * parent_bone.matrix[“ARMATURESPACE”].invert()
bone's action IPOs compiled in to list
removed redundant function arguments
Fuction Animation.SaveToDae : - new impementation
removed unused getEulerAnimation() function
function takes IPOs list as input argument
new function getLocalPoseMatrix added
Fuction SceneNode.SaveSceneToDae :
Added creation of Armature node as parent of Skeleton nodes
Controler transforms cleaned up
Node animation handling fixed
Fixed version converts quaternion to Matrix and then multiplies with BONESPACE matrix, and then converts to Euler angles.
Fixed version added an extra 'armature node' to decouple animation keys and initial transformations of armature object.
Apparently, Blender v 2.45 , 2.46, 2.47 and 2.48a have few bugs in COLLADA export that do not allow to produce correctly built Skin/Bone animation Dae files.
I did some research and found and fixed a number of bugs to make export work right. Also I submitted ticket in Blender Bug-Tracker system, so I hope those bugs will be fixed in upcoming Blender release soon.
Skin IDREF_Array joint id string values containing '.' character converted to '_'. For example, id value 'Foot_L.001' will be replaced with 'Foot_L_001'. The same way PyCollada library converts ids for 'id' attribute. Due to this bug skinning process fails to find Bone nodes.
Skin joints pose matrix calculations are updated to take into account rotations(local orientation) of a bone. Used to be only bone Head Positions. Most of exported animations were incorrect before that fix.
Some animation keys got removed from export. The issue was with check condition on summary rotation equals to 0. Which in some cases may be full rotation or back and forth rotation.
Weird animation artifacts, like, stretching of an animated character shoe noses during the walk, because skin joint weights were evenly distributed instead of using joint weight values from Blender core objects.
unpack content of the zip file in to temporary storage.
copy files to <Blender Home>/.blender/scripts/bpymodules/colladaImEx. You may want to save original files just in case.
and you are ready to do Collada export.
Also see readme.txt file in each zip file for instructions.