Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- for( i = 0; i < header->num_joints; i++, joint++ ) {
- float baseFrame[12], invBaseFrame[12];
- JointToMatrix( joint->rotate, joint->scale, joint->translate, baseFrame );
- Matrix34Invert( baseFrame, invBaseFrame );
- if ( joint->parent >= 0 )
- {
- Matrix34Multiply( jointMats + 2 * 12 * joint->parent, baseFrame, mat );
- mat += 12;
- Matrix34Multiply( invBaseFrame, jointMats + 2 * 12 * joint->parent + 12, mat );
- mat += 12;
- }
- else
- {
- Com_Memcpy( mat, baseFrame, sizeof(baseFrame) );
- mat += 12;
- Com_Memcpy( mat, invBaseFrame, sizeof(invBaseFrame) );
- mat += 12;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement