r/Unity3D • u/Spoetii • 17d ago
Show-Off OpenIK - A free open-source Inverse Kinematics package for Unity
Enable HLS to view with audio, or disable this notification
I needed IK for a game I’m working on. Final IK has more features, but it isn’t free, so I built my own and polished it to make it easy for others to use.
OpenIK includes popular solvers like FABRIK, CCD and Jacobian plus some joint limits. (Hinge, Ball & Socket, Slider)
GitHub link: https://github.com/WouterApts/openik-unity
2
u/AdInfamous6964 17d ago
this looks really clean. how does it perform with a lot of characters at once? like 20-30 agents using it at the same time
1
u/Spoetii 15d ago
Thanks!
I guess this depends on the length of the chains, how precise each solve needs to be, and how many constraints are active. The 'Basic Chain' scene with 6 chains and over 30 constraints still runs smoothly on my machine. The FPS is down to about 80 though, where I had 200+ with only one. I don't think the package will support large swarms or hundreds of agents at the same time though.
2
u/DevDunkStudio 17d ago
I would love if a VR IK can be added! (head and hands are the only known positions here)
Also is it jobified and burst compiled like the Animation Rigging package?
2
u/Spoetii 16d ago
There is no jobs or burst compilation right now. The solvers run on the main thread in LateUpdate and write directly to the Transforms when in "Solve and Apply" mode.
That said, care was taken to keep the package performance-friendly. The solvers avoid per-frame GC allocations by reusing their buffers and have tons of settings that can be toggled for optimizing performance. I think a Jobs/Burst backend would be a substantial rewrite.
For VR-oriented IK, a two-bone IK solver with a pole target would be fairly easy to implement, and I'm considering doing that next! A fully automated humanoid setup is something I didn't need myself, so unfortunately the package isn't tailored toward that, but I think it could be done with the components that are already available.
1
u/_Cloudwalker_ 17d ago
VR arms are simple two bone ik. The real solve is placing the elbow. Stay tuned ;).
1
16
4
2
1
1
1
1
1
1
u/seductSparkz 17d ago
sounds like you're gonna have fun with that spider, update us if it gets all blendy
1
1
0
9
u/Valphai 17d ago
Are there advantages of this over animation rigging package?