vpenades / SharpGLTF

glTF reader and writer for .NET Standard
MIT License
467 stars 75 forks source link

How to get the mesh bones ? #62

Closed EricBeetsOfficial-Opuscope closed 3 years ago

EricBeetsOfficial-Opuscope commented 4 years ago

Hi there,

I don't how to get the bones (associated joints) of a specific mesh. I can get the all joints but not the relationship with meshes (once a skinned model is loaded ..)

Thank in advance, Eric

vpenades commented 4 years ago

Given a specific Node, if it has a Mesh, and it's skinned, it will also contain a Skin.

The Skin object is in the Node, NOT in the Mesh.

The Skin object has an array of joints (and the corresponding inverse bind matrices) needed for skinning.