Coordinate Transformation in skeleton skin Animation

Source: Internet
Author: User

Background

Model View Transformation

OpenGL does not have a view matrix, but only a model view matrix. Generally, game engines abstract the view matrix.
The overall transformation is:

 
V' = projection * view * mode * V;

Parent-Child node Transformation

 
V' = worldmatrix * V = (parentworldmatrix * localmatrix) * V;
Skeleton Transformation

In fact, the joints actually represent, rather than the bones, but the bones are better understood.

By default, the coordinates of the pose Grid Object are converted to the local coordinate space (offsetmatrix) of the skeleton ).

After that, it is transformed from the skeleton space to the animation posture world coordinate (nodewroldmatrix ).

 
V' = nodewroldmatrix * offsetmatrix * V;

Here there is a bindshapematrix which does not know what it means. It is estimated that it is the offset when the mesh object is bound to the skeleton, that is:

Offsetmatrix = inversewroldmatrix (inverse world transformation) * bindshapematrix;

Because the MVP (mode view matrix) matrix already contains the M matrix, you must exclude the top-level transformation in the nodewroldmatrix or change the MVP to VP.

 
V '= projection * view * nodewroldmatrix * offsetmatrix * V;
Skin Transform

Skin transformation, the final matrix of each nodewroldmatrix * offsetmatrix is called a matrix palette.
Each skin vertex is associated with multiple bones, that is, the matrix in multiple matrix palette. Generally, four integer indexes are used for this purpose.
Multiply the matrix of each matrix palette, and then take the weighted average value, that is, the final position.

Vomit time

I have guessed most of these concepts, and I cannot find any such information.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.