Importing IKs via gLTF / glb objects

I want to clear this issue for me. I have a model that I’ve modeled and rigged using the Bender. I am an experienced Blender user. So, I have properly created all the IKs. I want to control model arms from the controller on the web page on demand. For this, I have tried to store bones that I want to control (IK controllers and/or the end-of-the-chain bones.) But the IK controller which functions properly on the Blender doesn’t affect the rest of the bones at all. When I change the end bones’ properties It just affects itself, not the rest of the bones.
So my question is; do I have to create an IK in the three.js or is there something that I may be skipped?

Unfortunately — IK constraints can neither be exported from Blender to any standard format I’m aware of, nor read by three.js from any format I’m aware of. three.js doesn’t include an IK system out of the box, though solutions like THREE.IK do exist. You would likely need to:

  1. Represent the IK constraints indirectly, by storing their properties in Blender “Custom Properties” and enabling the option in the glTF export menu to include Custom Properties.
  2. In three.js, rehydrate the IK constraints using those properties (found in object.userData) and the IK implementation of your choice.

EDIT: This example might be helpful as well.

1 Like

Thank you very much, that clears it up. But one last thing. In the last example, you showed; the issue was solved only using three.js CCDIKSolver, there is no external THREE.IK library that imported. All the other questions that I’ve read here also refer to THREE.IK. Confused me a little bit. Since it looks possible via three.js.

True, CCDIKSolver is an addon that ships alongside the three.js library, which I’d forgotten about — whether it’s a better choice than THREE.IK I’m not sure, though.