Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Model fails to import since extras property is only partially parsed #126

Closed
hybridherbst opened this issue Jan 5, 2024 · 3 comments
Closed
Assignees

Comments

@hybridherbst
Copy link

This fails completely:
kid.glb.zip

@hybridherbst
Copy link
Author

Looks like there's incorrect parsing of the mesh going on: instead of parsing the "extras" property as part of the array deserializerFunc, the loop repeats for all sub properties of extras, passing them to the deserializerFunc which ends up creating empty primitives with no attributes at all.

So two bugs:

  • empty primitives/no attributes result in exceptions – not sure if that is valid glTF but I think an uncaught exception is still not good
  • parsing is wrong in MeshPrimitive.Deserialize

hybridherbst added a commit that referenced this issue Jan 6, 2024
@hybridherbst
Copy link
Author

hybridherbst commented Jan 6, 2024

Turns out this was related: KhronosGroup/glTF#1036
The primitives.extra property was parsed for targetNames, but not in a correct way, so nested objects as primitives.extra messed up the import.

@hybridherbst
Copy link
Author

Fixed on dev

@hybridherbst hybridherbst changed the title Model exported from Spline fails to import Model fails to import since extras property is only partially parsed Jan 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants