SkinnedMesh gltf character distorted mesh
Closed this issue · 10 comments
trying to get a gltf avatar model with this greate THREE.IK
the bones looks like correct for me only the mesh is bind wrong
THREE.IK master and aframe 0.9 with THREE 101
i have created this model with mixamo and blender like described in this blog post
https://www.donmccurdy.com/2017/11/06/creating-animated-gltf-characters-with-mixamo-and-blender/
ok i have done some more testing with new blender 2.80 beta ( importing the fbx from mixamo and export it with gltf exporter) result looks similar
https://truthful-web.glitch.me
on the fbx importing i use this fbx settings like described in the blog post
https://www.donmccurdy.com/assets/images/2017/11/manual_orientation.png
https://www.donmccurdy.com/assets/images/2017/11/bone_orientation.png
THREE.IK expects +Z to be facing the children joint; this is a potential solution to not requiring a specific orientation of skeleton, as all tools handle it differently
i have to less knowledge on this, for what is the best solution for this
After doing the axis conversion to +Z Forward on your mesh, the bind matrices are fixed :)
https://dashing-floor.glitch.me/
There is now a utility in the AxisUtils.js
file called setZForward
. Using this function on the root bone will reset the bone quaternions / positions to follow a +Z Forward coordinate system. @jsantell I'd like your feedback on where you think this utility should go :)
This is the code I added to your project. I had to rebind two meshes because both of them are using the same skeleton.
setZForward(rootBone);
rigMesh.bind(rigMesh.skeleton)
rigMesh2.bind(rigMesh2.skeleton)
@sneha-belkhale this is awesome! thank you so much!
would be cool if you want to join my little discord server, for my freetime side project
https://discord.gg/cNfG834
Thanks to @sneha-belkhale, I think with #9, this should be solved, how does it look @arpu?
yeahh this works now fine