:orphan:

##########
FBX Reader
##########

.. rst-class:: format-title-block

+---------------------------------------------------------------------------------+
|                        **FBX**                                                  |
+-----------------------------------------+---------------------------------------+
| **File Extension**                      | FBX                                   |
+-----------------------------------------+---------------------------------------+
| **Supported Versions**                  | ASCII: from 7100 to 7500, Binary: All |
+-----------------------------------------+---------------------------------------+
| ***Platforms**                          | |wy| |ly| |my| |an| |iy|              |
+-----------------------------------------+---------------------------------------+
| :ref:`fbx_rd_tessellation`              | |t_green| Supported                   | 
+-----------------------------------------+---------------------------------------+
| :ref:`fbx_rd_brep`                      | |c_grey| Unsupported by format        | 
+-----------------------------------------+---------------------------------------+
| :ref:`fbx_rd_pmi`                       | |c_grey| Unsupported by format        | 
+-----------------------------------------+---------------------------------------+

FBX is a proprietary 3D file format developed by Autodesk for exchanging 3D models, 
scenes, textures, and animation data between digital content creation tools.

The HOOPS Exchange FBX reader provides access to the tessellated geometry and 
associated texture data stored in an FBX file for visualization, but it does not extract 
CAD-specific information such as B-rep, PMI, or assembly structure.

A file does not need to have a particular extension to be read correctly by HOOPS Exchange. 
However, the file extensions of FBX files that you can expect to be loaded by HOOPS 
Exchange include:

* `.fbx`

How to Import From FBX 
======================

Reading ``FBX`` files follows the same pattern as other formats: configure load parameters, then call the standard load function.
                                                                                                                                      
To load an FBX file, use :cpp:func:`A3DAsmModelFileLoadFromFile`.
The :cpp:struct:`A3DParamsLoadData` structure is used to customize the loading behavior:

.. code-block:: c

   A3DAsmModelFile* pModelFile = 0;

   A3DRWParamsLoadData sReadParam = A3D_MAKE_DATA(A3DRWParamsLoadData);
   sReadParam.m_sGeneral.m_bReadSolids = true;

   // ... set other A3DRWParamsLoadData fields as necessary

   A3DAsmModelFileLoadFromFile("path/to/file.fbx", &sReadParam, &pModelFile);

See :doc:`/guide/basic_operations/load_model` for more about loading model files.

.. _fbx_rd_tessellation: 

Tessellation
============

Geometry
********

As noted above, FBX is a tessellation-only format. 
Consequently, other data such as Product Manufacturing Information (PMI) and Boundary Representation (B-rep) 
are not supported by the format, including when using FBX with HOOPS Exchange.

.. _fbx_rd_brep: 

Boundary Representation (B-rep)
===============================

As noted above, Boundary Representation is unsupported by FBX.

.. _fbx_rd_pmi: 

Product Manufacturing Information (PMI)
=======================================

As noted above, Product Manufacturing Information (PMI) is unsupported by FBX.

Textures
========

Textures are fully supported when parsing FBX files with HOOPS Exchange.

The detailed description of the material data format is included in the documentation of the :struct:`A3DGraphMaterialData` structure.
For more information about accessing textures and attributes, please read the documentation 
for the :struct:`A3DGlobalData`, :struct:`A3DGraphMaterialData`, :struct:`A3DGraphTextureApplicationData` and :struct:`A3DMiscAttributeData` structures.

Miscellaneous
=============

Limitations
***********

* Reading FBX is only supported on Windows, macOS, and Linux platforms.
* Reading FBX-DOM files is unsupported.
