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

Bone components that are assigned to bones that aren't in the top level of the hierarchy aren't imported #123

Closed
keianhzo opened this issue Sep 14, 2022 · 1 comment · Fixed by #63
Labels
bug Something isn't working Importer This issues is related to the glTF importer P0 Needs to be addressed immediatly

Comments

@keianhzo
Copy link
Contributor

Description
Bone components that are assigned to bones that aren't in the top level of the hierarchy aren't imported

@keianhzo keianhzo added bug Something isn't working P0 Needs to be addressed immediatly Importer This issues is related to the glTF importer labels Sep 14, 2022
@keianhzo keianhzo linked a pull request Sep 14, 2022 that will close this issue
Exairnous added a commit to Exairnous/hubs-blender-exporter that referenced this issue Sep 19, 2022
This fixes bone components not being imported if they aren't in the
top level of the hierarchy.

Note:
The gltf bones aren't in the same order as the armature bones, this
is by design.  I considered using the bone order to map the gltf
bones to the armature bones (potentially faster), but decided it would
be too fragile, and mapping it would have potentially been slower anyway.

I loop through the bones in the armature and access the gltf bones
by name rather than the other way around because Blender's internal
data structures are mostly based on linked lists, so looping over it
is much more performant than doing lookups for each item.
@keianhzo
Copy link
Contributor Author

keianhzo commented Nov 2, 2022

This has been fixed here: 0fb5c34 and its available in #63 already

@keianhzo keianhzo closed this as completed Nov 2, 2022
keianhzo pushed a commit to keianhzo/hubs-blender-exporter that referenced this issue Nov 7, 2022
This fixes bone components not being imported if they aren't in the
top level of the hierarchy.

Note:
The gltf bones aren't in the same order as the armature bones, this
is by design.  I considered using the bone order to map the gltf
bones to the armature bones (potentially faster), but decided it would
be too fragile, and mapping it would have potentially been slower anyway.

I loop through the bones in the armature and access the gltf bones
by name rather than the other way around because Blender's internal
data structures are mostly based on linked lists, so looping over it
is much more performant than doing lookups for each item.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Importer This issues is related to the glTF importer P0 Needs to be addressed immediatly
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant