question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Getting error when running this script...

See original GitHub issue
192-168-1-4:Source jimmygunawan$ python gltf2usd.py -g /Users/jimmygunawan/tentacle.gltf  -o tentacle.usda
Traceback (most recent call last):
  File "gltf2usd.py", line 1081, in <module>
    convert_to_usd(args.gltf_file, args.usd_file, args.fps, args.verbose)
  File "gltf2usd.py", line 1070, in convert_to_usd
    GLTF2USD(gltf_file=gltf_file, usd_file=usd_file, fps=fps, verbose=verbose)
  File "gltf2usd.py", line 62, in __init__
    self.convert()
  File "gltf2usd.py", line 1056, in convert
    self.convert_nodes_to_xform()
  File "gltf2usd.py", line 98, in convert_nodes_to_xform
    self._convert_node_to_xform(node, node_index, xform_name)
  File "gltf2usd.py", line 149, in _convert_node_to_xform
    self._convert_node_to_xform(self.gltf_loader.json_data['nodes'][child_index], child_index, xform_path + '/node{}'.format(child_index))
  File "gltf2usd.py", line 145, in _convert_node_to_xform
    self._convert_mesh_to_xform(self.gltf_loader.json_data['meshes'][node['mesh']], usd_parent_node, node_index)
  File "gltf2usd.py", line 169, in _convert_mesh_to_xform
    self._convert_primitive_to_mesh(name=mesh_primitive_name, primitive=mesh_primitive, usd_parent_node=usd_parent_node, node_index=node_index, double_sided = double_sided)
  File "gltf2usd.py", line 230, in _convert_primitive_to_mesh
    self._convert_skin_to_usd(gltf_node, node_index, usd_parent_node, mesh)
  File "gltf2usd.py", line 687, in _convert_skin_to_usd
    skeleton.CreateBindTransformsAttr().Set(bind_matrices)
AttributeError: 'Skeleton' object has no attribute 'CreateBindTransformsAttr'

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:8 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
kcoleycommented, Aug 16, 2018

Hi @enzyme69, thanks for trying out this tool and flagging your issues!

Did you build your USD against version 18.09? Some of the API calls I am using, such as CreateBindTransformsAttr are not available in earlier versions of USD. Updating your USD should at least resolve this error.

The “File name too long” error is because I have not handled base64 strings yet during conversion, so it only handles glTF assets with external texture references. I plan on supporting that very soon.

The last error is a bug, since shutil.copyfile does not overwrite files in the same directory. As a temporary solution, can you try running this command?:

python gltf2usd.py -g monster.gltf -o monster/monster.usda

This should create a new directory called “monster” and export all the textures and USD file within it. I will work on fixing the shutil issue.

Again thanks for trying out this tool and I’ll get to these bugs ASAP!

0reactions
kcoleycommented, Aug 17, 2018

@enzyme69 great! Btw, I made some tweaks to gltf2usd this morning, so that the animations play on iOS now. Feel free to pull the latest master and see if that works for you.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Script Error: What It Is And How To Fix It - Lifewire
Script errors indicate that a script on the website you're visiting has malfunctioned in some way. It may have failed to run, failed...
Read more >
How to best resolve script error messages on personal computer
A: Script error messages tend to appear when one's browser is out of date. What happens is the website you are visiting contains...
Read more >
What causes a Script error and how to solve them · Raygun Blog
While Script error is caused by violating the browser's same-origin policy, a Long Running Script indicates performance issues.
Read more >
How to fix Script Error in Windows? - ugetfix.com
Solution 5. Turn off Scripting Errors in IE · Press the Windows Key + R key to open the Run box · Type...
Read more >
What are Script Errors and How Can We Address Them?
Script Errors are errors that the browser sends to the onerror callback when they originate from a third-party script. It usually happens when ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found