Dev:Py/Scripts/Import-Export/UnifiedFBX

提供: wiki
< Dev:Py‎ | Scripts‎ | Import-Export
2018年6月29日 (金) 04:40時点におけるYamyam (トーク | 投稿記録)による版 (1版 をインポートしました)
(差分) ← 古い版 | 最新版 (差分) | 新しい版 → (差分)
移動先: 案内検索

Unified FBX

Documentation
Script manual page Extensions:2.5/Py/Scripts/Import-Export/Autodesk_FBX
Script development page Dev:2.5/Py/Scripts/Import-Export/UnifiedFBX
Project Page Extensions:2.5/Py/Scripts/Import-Export/UnifiedFBX

Unified FBX Design Goals

Have one FBX exporter script with options to support different applications requirements. The script should be able to export models and animations suitable for use with, Unity, UDK, XNA and others as their requirements become known.

This was at the request of Campbell Barton (ideasman_42) 9 Jan 2011.

It is likely that by using one script it will be better supported in future releases.

XNA Requirements

  • The armature must be a type of 'Limb' in all places in the file.
  • The armature is treated as a special part of the skeleton by the XNA import processor.
  • The type 'Limb' and 'LimbNode' do the same thing as far as I can tell.
  • The root object is the scene
  • The armature, textures and meshes must all be parented to the scene.
  • The first bone must be parented to the armature.
  • The Bind Pose must be included with the 'Mesh'.
  • The Bind Pose is not needed for animation only files but does no harm.
  • Linear or curve L or C,n make no difference to the result for XNA.
  • The Rotation (TX_CHAN == 'R') of the takes can be based on the array element [0] or [1].
  • The order of the connections does not matter although I would always want the bones in order just in case.
  • XNA does not use the cameras
  • XNA does not use the lamps
  • XNA does not use the Empties
  • XNA does not use Edges.
  • XNA generates intermittent errors during importing if the FBX file contains loose edges in the list of faces!
  • XNA can only import one take per FBX file, the name 'Default_Take is unhelpful when trying to merge the separate animations!
  • Ideally uv textures should be in the same folder as the FBX file when importing in to the XNA content pipeline. This is more to do with the ease of distributing the finished applications rather than a strict requirement.
Blender to XNA

I export models and animations from Blender to Microsoft XNA regularly for my game 'Diabolical: The Shooter' Please contact me via my blog if you think there is a problem with the script relating to its use with XNA.

Work In Progress on any XNA specific changes are likely to be in the following Subversion project.


Unity Requirements

Unity has its own integration with Blender and uses the official Blender export_fbx.py script but called with its own settings from Unity.

There are settings that can be made at the Unity end to disable the export of cameras and lamps.

  • Do not export Cameras
  • Do not export Lamps
  • (To be confirmed) Use 'Default Take' as the action name - set to True in export_fbx.py for compatibility with the Unity script

I am not a Unity expert the above information was taken from their forum and changes to the script. Please feel free to edit and correct or extend the information if you are a Unity user.

UDK Requirements

  • Face Smoothing
  • The bone and armature parenting is important
  • The connections order is important
  • The object relations are important
  • The root object should be the scene

I am not a UDK expert the above information was taken from their forum and changes to the export script to make it compatible. Please feel free to edit and correct or extend the information if you are a UDK user.