I patched Blender-Plugin for Animation Compornent

Topics: User Forum
Mar 23, 2007 at 8:23 AM
Edited Mar 23, 2007 at 8:28 AM
Hi all,

I noticed that Blender is impossible to export models correctly in some cases. And so, I patched the default Blender exporter plugin quickly.

Download from here;

The default exporter doesn't handle the plural root frames. So if a model has IK bones which don't have a parent, the exporter chooses the last object of the armature as the root frame. By that, important bones having actual vertexes are not exported in some cases. These cases raise Exception Error in the ModelAnimator constructor, because the model doesn't have bones which are specified by skinmesh tags.

My patch removes the specific bones which have "IK_" name and don't belong to a parent, from root object candidates.

This is not perfect, but may make it possible to export some of your models correctly for Animation Component Library.

For more informations, see "README" in the archive.

Best Regards,
Mar 24, 2007 at 3:53 PM
Thanks, I'll certainly give it a try if I run into any problems, although I'll have to study the code and/or reread your post a few more times to fully understand what it does.
Oct 16, 2007 at 6:26 PM
I've been having problems for more than a week and I'm way behind on my project. I can't get Blender to export my animated model at ALL! Neither the original script nor this one works. I get the error below. I'm completely lost when it comes to python, so I just don't know what to do to fix the problem.


Compiled with Python version 2.5.
Checking for installed Python... got it!
Traceback (most recent call last):
File "<string>", line 162, in draw
File "<string>", line 76, in my_callback
File "<string>", line 388, in SelectObjs
File "<string>", line 346, in writeObjFrames
File "<string>", line 511, in writeRootBone
File "<string>", line 479, in exportMeshArm
AttributeError: 'NoneType' object has no attribute 'getData'


#Export Mesh with Armature
def exportMeshArm(self,arm,armob,chobj):
tex = []
(479) mesh = ch_obj.getData()
self.writeTextures(ch_obj, tex)
self.writeMeshcoordArm(chobj ,armob)
self.writeMeshMaterialList(ch_obj, mesh, tex)
self.writeMeshNormals(ch_obj, mesh)
self.writeMeshTextureCoords(ch_obj, mesh)
#self.file.write(" } // End of the Frame %s \n" % (ch_obj.name))
self.file.write(" } // End of the Object %s \n" % (ch_obj.name))
Oct 16, 2007 at 7:06 PM
Edited Oct 16, 2007 at 7:29 PM
Guess I should make a separate thread.