My noob IK implementation

Discussion about everything. New games, 3d math, development tips...
Post Reply
thanhle
Posts: 325
Joined: Wed Jun 12, 2013 8:09 am

My noob IK implementation

Post by thanhle »

Hi guys,
I haven't done any Irrlicht for so long. Just have some time to do some coding on IK this weak.

I have implement CCD, Jacobian Least Squares and Jacobian transpose Inverse Kinematic. CCD motion is not realistic for hinge joint robot (maybe I didn't code it right?, don't know). My version of Jacobian LS and Jacobian Transpose perform quite well.

Sorry for the render, I don't know how to make it look good yet. Looks like some culling issue? I don't know.

https://www.youtube.com/watch?v=uqmbVAO ... e=youtu.be

Cheers
Thanh
christianclavet
Posts: 1638
Joined: Mon Apr 30, 2007 3:24 am
Location: Montreal, CANADA
Contact:

Re: My noob IK implementation

Post by christianclavet »

Hi, Nice video! Is your code/class very big for this? Have you tried it with longer chains?

The rendering issue, is just caused because there is no texture on the robots and you activated "debug" rendering on them. The white lines are simply the bounding box being rendered only in the model and not rendered outside of them. I often see this when I activate debug rendering on some models.
thanhle
Posts: 325
Joined: Wed Jun 12, 2013 8:09 am

Re: My noob IK implementation

Post by thanhle »

Hi mate, thanks for comment. I've fixed the lighting issue but didn't bother update the video.
The robot is 6dof. I've tested added a translation motion as well. It seems to work as well. I need to do a little refactor and will post in the snippet forum.

The class is not big at all. But it needs Eigen library to do the Matrix Psuedo inverse and calculation.
I'm trying to implement SVD for Pseudo Inverse. But Eigen 3 giving me some problem at the moment.

Cheers
thanh
CuteAlien
Admin
Posts: 9628
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: My noob IK implementation

Post by CuteAlien »

Interesting stuff. Any chance you are going to open-source it? Also the render-problems are probably because the whole mesh has transparency. Maybe disable transparency for the mesh and then disable z-buffer before writing the lines (so you can still see those).
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
thanhle
Posts: 325
Joined: Wed Jun 12, 2013 8:09 am

Re: My noob IK implementation

Post by thanhle »

Hi CuteAlien,
I'll post the code in the snippet forum when I have sometime during the break.
Regards,
Thanh
netpipe
Posts: 669
Joined: Fri Jun 06, 2008 12:50 pm
Location: Edmonton, Alberta, Canada
Contact:

Re: My noob IK implementation

Post by netpipe »

i keep checking for it :)
Live long and phosphor!
-- https://github.com/netpipe/Luna Game Engine Status 95%
thanhle
Posts: 325
Joined: Wed Jun 12, 2013 8:09 am

Re: My noob IK implementation

Post by thanhle »

Will come back to this. At the moment I'm porting irrlicht UI to Qt instead of .Net.
Anyway doing this slowly, as I'm kind of having 2 projects at work atm.
Regards
thanh
thanhle
Posts: 325
Joined: Wed Jun 12, 2013 8:09 am

Re: My noob IK implementation

Post by thanhle »

Simple example on snippet forum.
Regards
thanh
Post Reply