Tuesday 30 November 2010

Blender 2.5 to XNA 4 animated FBX models

The following post is out of date because as from Blender 2.56 the scripts mentioned are all shipped with Blender. See the following post for more up to date information:


Following on from my previous post on this subject I have managed to create an FBX exporter script for Blender 2.55 Beta that works with keyframe animations and imports in to XNA 4.0.

Due to the limitations with the Autodesk FBX importer that ships with XNA 4.0 the animations need to be loaded individually from separate FBX files but there are simple solutions available to work with that.  Details and other links are in the Instructions with each of the following projects:

The package with several XNA FBX exporters for Blender 2.5 can be downloaded from:
The most recent instructions are on the Blender Wiki:

An XNA model viewer that has an option to load FBX files as separate animations:

The XNA TakeExtractor project also demonstrates how to rotate models and their animations within the pipeline.  That is useful for adjusting Blender models which face Z up to XNA's default which is Y up.  Use a rotation while loading of X = 90, Y = 0, Z = 180.   I think that ends up facing backwards because that is how my entire game appears to work and there is too much code for me to bother to change it!

No comments: