kcoley / gltf2usd

command-line utility for converting glTF 2.0 models to USD
MIT License
263 stars 39 forks source link

Error converting GLTF with animations #184

Open makc opened 4 years ago

makc commented 4 years ago

So we get something like this:

First: File "/somewhere/gltf2usd-master/Source/gltf2usd.py", line 859, in <module>
Last: File "/somewhere/gltf2usd-master/Source/gltf2usd.py", line 524, in _create_keyframe_transform_node
Boost.Python.ArgumentError: Python argument types in pxr.UsdSkel._usdSkel.DecomposeTransform(Matrix4d, Vec3f, Quatf, Vec3h) 
did not match C++ signature:
DecomposeTransform(pxrInternal_v0_19__pxrReserved__::GfMatrix4d)

Trying to convert this file: Archive.zip Not sure if it is related to e g #168 as they do not seem to have actual errors

makc commented 4 years ago

Looks like this is line 530 now. From this it looks like the code should be

 translation,rotation,scale = UsdSkel.DecomposeTransform(usd_matrix)

maybe?

stetttho commented 3 years ago

i had the same issue, seems it's due to an API change in the latest release of Pixars USD. I therefore installed version 18.11 instead (you can grab it from https://github.com/PixarAnimationStudios/USD/releases). The error didn't show up anymore after that, but unfortunatly animations still didn't work (animations were done with Unity which worked fine in the gltf format).

still big thanks to @kcoley and everyone else who contributed to this tool, except the missing animations it works fine!