The main concept is as follows: I modified the Vertex buffer object in order to fit the information of bones indices and bone weights, then for every frame of the animation I modify the bone matrix (an array of transformation matrices for each bone) with the appropiate matrix (for each joint I create an identity matrix and multiply it by it's orientation and position, then I multiply the result by the inverse of the bind pose and it's ready to go to the shader).
This works OK when the boneMatrix array is filled with identity matrices (by concept it should render the bindPose and it does). However when I try to load an animation the movements appear messed up and clipped. I discarded a wrong/corrupt version of the md5mesh / md5anim by loading them in an MD5 viewer.
Here there is an example of what happens when the boneMat array is filled with identity matrices:
I think this is the way the model should look, but when I try to animate it...
The general movement of the mesh is correct but some vertices move with an strange direction / orientation which forces a lot of clipping to occur.
Maybe someone experienced in the matter can spot the problem directly from the image, if not I' willing to provide any part of my modifications on the md5Mesh lib.
Any help will be appreciated, I've really hit a wall with this!
Thanks in advance.