Spine Skeletal animation knowledge popularization

Source: Internet
Author: User

some basic concepts

The basic concepts of skeletal animation are described below to facilitate literacy for children's shoes (such as technology) that are poorly understood by skeletal animation. Children's shoes that are already familiar with skeletal animation can be skipped directly.

Fundamentals of Animation

Animation, as the name implies, is an active painting, painting can be transformed over time, thus giving people a sense of continuous movement.

In the game there are generally two ways to make animations: frame-by-box animation and tweened animation.

One-frame animation draws a picture for each frame, and then plays the picture with a certain speed (frame rate, number of frames per second) to achieve the effect of the animation.

tweened animation is relatively lazy, it does not draw a picture for each frame, but a "dynamic" shape to set the key frame, and the key frame between the different interpolation algorithm for automatic completion of the middle frame of the shape of the change trajectory.

Compared to frame-by-frames animations, motion tweens save more pictures, make the animation run with less memory and the final package size smaller, while reducing the amount of work on the original painting, but its picture may be slightly inferior to frame-by-frames animation. The pros and cons need to be balanced by developers.

keyframe (key frame)

KeyFrames are actually "changes" in the form to be moved and we manually record the frames of these changes, and the rest of the frames are called tweened frames.

The key frame is called "key" because the deformation parameters of the shape on each tween frame are automatically deduced by the program according to the two key frames before and after it.

Assuming that the body is in the PA position in frame A, we mark the frame as a keyframe, which is generally referred to as the "K-frame". Then in frame a+n, we set the position of the shape to PN, we make K frames in the a+n frame. So we have two keyframes, and when we play an animation from A to a+n frame, we'll find that the shape has a displacement animation from PA to PN.

Skeletal animation (skeleton animation)

Imagine that you are sitting in front of a computer typing, your fingers are moving, and your wrist is moving, but your torso remains motionless and your elbows are fixed on the table. It's all because your bones drive your muscles and your skin, so you can perform a series of typing actions.

Skeletal animation is the use of this principle, which is a tween animation. It consists of two parts: the Skeleton (bone) and the Skin (Skin/mesh).

The skin is a material that can be thought of as a decal, which shows the animation's outward appearance. The skeleton itself is invisible, but deforming it will lead to various deformations of the skin, resulting in a variety of more realistic-looking animations. Spine

Skin Animation (skinned animation)

In general, a bone is usually bound to a map, which completely controls the deformation of the map. But because it is rigid binding, when the joint movement, prone to cracks, as shown below.

As the hardware improves, skeletal animation can deform every vertex of the map. A sleek triangular mesh called skinning (skin) binds to the bone, and the vertices of its triangles track the movement of the bone and produce the corresponding movement. Each vertex on the skin can be bound to multiple bones by weight, resulting in a natural stretching effect.

In this paper, the flexible bending effect of the legs can be realized by using the skin animation.

weight (weights)

The above mentioned weight is actually a very important concept.

Weight is a factor affecting the vertices of the skin that are affected by different bones. The sum is 1.

Imagine that you bend your elbow and think of a point on the skin of your elbow on your forearm, which is primarily affected by the forearm skeleton, but it is also affected by the upper arm skeleton. Assuming that it is affected by the forearm skeleton by 80% of its total deformation, the weight of its forearm bone is 0.8, and the corresponding upper arm bone weighs 1–0.8 = 0.2, because other bones have negligible effects on it.

The above is the weight of the visual summary, the weight of the skin is affected by the different bones of the proportion of its deformation, reasonable allocation of the weight of each skin vertex is very important.

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.