iOS Augmented Reality USDZ creation and deployment

Create 3D Model Requirements

Create and export 3D model with textures and animation as FBX from Maya. Do note the development scale has to be in meters, save all texture in png or jpg as tga is not recognised during conversion.

Conversion Tool Preparation

The tool (USDPython) for conversion have to be downloaded from apple developer portal(developer account required):

https://developer.apple.com/download/more/?=USDPython

Once downloaded, install the files and it can be found in application folder

Double click on the USD.command and it may tell you if anything is not being installed yet.

Setup environment variable

sudo nano ~/.zshrc

Here insert the following:

export PATH="/Users/dreamaker/usdpython/USD:$PATH"
export PATH="/Users/dreamaker/usdpython/usdzconvert:$PATH"
export PYTHONPATH="/Users/dreamaker/usdpython/USD/lib/python:$PYTHONPATH"
export PYTHONPATH="/Applications/Autodesk/FBXPythonSDK/2020.0.1/lib/Python27_ub:$PYTHONPATH"

to setup FBX, first install the Autodesk FBX SDK
https://www.autodesk.com/developer-network/platform-technologies/fbx-sdk-2019-5

Find the path of the installed FBX.so file location.

Ensure the python install on system version is consistent with FBX SDK version. in this case, python27 should be used.

Add the path to the the USD.command with

sudo nano /Applications/usdpython/USD.command

to insert the path for FBX conversion.

Conversion

Now rerun the USD.command

Now we can use the following command to convert glb, gltf or FBX into USDZ format

usdzconvert YOUR.fbx