I need animated 3D models, and skeletal animation is pretty much standard everywhere. I was surprised by the lack of information on the internet about it or maybe I'm just looking in the wrong places.
I understand the theory; each vertex is given a number of bones that affect it, and the vertex is transformed in a vertex shader. In practice I have no idea how to do this, again because I haven't studied university math yet. As far as I've managed to uncover each bone is a 4x4 transformation matrix. Bones also have a hierarchy (fingers attached to hand, hand attached to elbow, elbow attached to shoulder, e.t.c). In the 3D model format I want to implement a loader for bones are stored as a 3D rotation vector + an angle and a 3D translation vector.
My real question is: How do I generate these matrices? Create an identity matrix, rotate it and translate it? The other way around? What about the hierarchy? How/when do I multiply it with its parent matrix? WHAT IS GOING ON?!
When I have my bone matrices loaded and ready I just send them as instance specific attributes to GLSL and access them in a vertex shader. So I multiply it by the model matrix first, then I transform this vertex with the bone matrices and average the result? Ah, matrices... I've hated you since the second movie!!!
I do realize that this is indeed over my head, but I just want to get it working more than actually understanding everything completely...