LoginSignup
1
1

More than 3 years have passed since last update.

FBX SDK Pythonが対応しているファイル形式一覧

Last updated at Posted at 2019-10-11

FBX SDK Python 2019 が対応しているファイル形式一覧

公式サイトを見ると、C++版のFBX SDKは大量のファイルフォーマットをサポートしているようなのですが、どうやらPython版はすべて対応しているわけではないみたいでしたので、対応しているフォーマットを調査してみました。

書き込み可能なファイル形式一覧

以下が一覧です。IndexDescriptionは、あくまで私の環境(後述)での値です。他の環境では異なる可能性がありますのでご注意ください。

Index Description
0 FBX binary (*.fbx)
1 FBX ascii (*.fbx)
2 FBX encrypted (*.fbx)
3 FBX 6.0 binary (*.fbx)
4 FBX 6.0 ascii (*.fbx)
5 FBX 6.0 encrypted (*.fbx)
6 AutoCAD DXF (*.dxf)
7 Alias OBJ (*.obj)
8 Collada DAE (*.dae)
9 Biovision BVH (*.bvh)
10 Motion Analysis HTR (*.htr)
11 Motion Analysis TRC (*.trc)
12 Acclaim ASF (*.asf)
13 Acclaim AMC (*.amc)
14 Vicon C3D (*.c3d)
15 Adaptive Optics AOA (*.aoa)
16 Superfluo MCD (*.mcd)

読み込み可能なファイル形式一覧

以下が一覧です。IndexDescriptionは、あくまで私の環境(後述)での値です。他の環境では異なる可能性がありますのでご注意ください。

Index Description
0 FBX (*.fbx)
1 AutoCAD DXF (*.dxf)
2 Alias OBJ (*.obj)
3 3D Studio 3DS (*.3ds)
4 Collada DAE (*.dae)
5 Alembic ABC (*.abc)
6 Biovision BVH (*.bvh)
7 Motion Analysis HTR (*.htr)
8 Motion Analysis TRC (*.trc)
9 Acclaim ASF (*.asf)
10 Acclaim AMC (*.amc)
11 Vicon C3D (*.c3d)
12 Adaptive Optics AOA (*.aoa)
13 Superfluo MCD (*.mcd)
14 (*.zip)

調査方法

IndexDescription は以下のコードで確認しました。

# 書き込み可能な形式一覧を出力
for formatIndex in range(manager.GetIOPluginRegistry().GetWriterFormatCount()):
    description = manager.GetIOPluginRegistry().GetWriterFormatDescription(formatIndex)
    print(formatIndex, description)

# 読み込み可能な形式一覧を出力
for formatIndex in range(manager.GetIOPluginRegistry().GetReaderFormatCount()):
    description = manager.GetIOPluginRegistry().GetReaderFormatDescription(formatIndex)
    print(formatIndex, description)

manager には FbxManager.Create() で生成したインスタンスを入力してください。

サンプルプロジェクトはこちらに置きます。
GitHub/segurvita/fbx_sdk_python_sample/convert_fbx/list_format.py

以下の2つの環境で試し、同じ値が出力さえることを確認しました。

Windows環境

  • Windows 10 64bit
  • Python 2.7
  • FBX SDK Python 2019.5

Linux環境

  • Alpine Linux v3.9
  • Python 2.7
  • FBX SDK Python 2019.2

さいごに

読み込みと書き込みでIndexが変わるのがちょっとややこしいですね。。。

以下のサイトを参考にさせていただきました。ありがとうございます。

1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1