Cinemática inversa (curva)¶
La cinemática inversa basada en curvas es una restricción que alinea una cadena de huesos con respecto a una curva. Mediante el aprovechamiento de la facilidad y flexibilidad para alcanzar resultados estéticamente satisfactorios ofrecida por las curvas, y la predictibilidad y el control bien integrado ofrecido por los huesos, la cinemática inversa basada en curvas es una herramienta invaluable dentro del arsenal de construcción de sistemas de control. Resulta particularmente apropiada para controlar partes corporales flexibles, tales como colas, tentáculos y columnas vertebrales, así como también elementos inorgánicos como cuerdas o cadenas.
Es posible encontrar una descripción completa de las opciones de cinemática inversa basada en curvas en la sección Cinemática inversa (curva).
Configuración básica¶
The Spline IK Constraint is not strictly an Inverse Kinematics method (i.e. IK Constraint), but rather a Forward Kinematics method (i.e. normal bone posing). However, it still shares some characteristics of the IK Constraint, such as operating on multiple bones, not being usable for Objects, and being evaluated after all other constraints have been evaluated. It should be noted that if a Standard IK chain and a Spline IK chain both affect a bone at the same time the Standard IK chain takes priority. Such setups are best avoided though, since the results may be difficult to control.
To setup Spline IK, it is necessary to have a chain of connected bones and a curve to constrain these bones to:
With the last bone in the chain selected, add a Spline IK Constraint from the Bone Constraints tab in the Properties.
Set the Chain Length setting to the number of bones in the chain (starting from and including the selected bone) that should be influenced by the curve.
Finally, set the Target field to the curve that should control the curve.
Congratulations, the bone chain is now controlled by the curve.
Opciones y controles¶
For the precise list of options, see Spline IK constraint. This section is intended to introduce the workflow.
Control del giro¶
To control the Roll of the Spline IK chain, the standard methods of rotating the bones in the chain along their local Y axes still apply. For example, start at the farthest bone and simply rotate the bones in the chain around their local Y axes to adjust the roll of the chain from that point onward.
Applying Copy Rotation constraints on the bones also works.
Nota
There are a couple of limitations to consider:
Bones do not inherit a curve’s tilt value to control their roll.
There is no way of automatically creating a twisting effect where a dampened rotation is inherited up the chain. Consider using Bendy Bones instead.
Controles de desplazamiento¶
The entire bone chain can be made to follow the shape of the curve while still being able to be placed at an arbitrary point in 3D space when the Chain Offset option is enabled. By default, this option is not enabled, and the bones will be made to follow the curve in its untransformed position.
Control de longitud¶
The Y Scale Mode setting can be used to choose the way bones are scaled length-wise. The available options allow stretching the bone chain to fit the curve, using the pre-IK scaling, or doing neither. In addition, the scale of the curve Object affects the result.
Controles de grosor¶
The thickness of the bones in the chain is controlled using the constraint’s XZ Scale Mode setting. This setting determines the method used for determining the scaling on the X and Z axes of each bone in the chain.
Los modos disponibles son:
- Ninguno
This option keeps the X and Z scaling factors as 1.0.
- Preservar volumen
The X and Z scaling factors are taken as the inverse of the Y scaling factor (length of the bone), maintaining the “volume” of the bone.
- Original de los huesos
This options just uses the X and Z scaling factors the bone would have after being evaluated in the standard way.
In addition to these modes, there is an option, Use Curve Radius. When this option is enabled, the average radius of the radii of the points on the curve where the joints of each bone are placed, are used to derive X and Z scaling factors. This allows the scaling effects, determined using the modes above, to be tweaked as necessary for artistic control.
Consejos para una buena configuración¶
For optimal deformations, it is recommended that the bones are roughly the same length, and that they are not too long, to facilitate a better fit to the curve. Also, bones should ideally be created in a way that follows the shape of the curve in its “rest pose” shape, to minimize the problems in areas where the curve has sharp bends which may be especially noticeable when stretching is disabled.
For control of the curve, it is recommended that hooks (in particular, Bone Hooks) are used to control the control points of the curve, with one hook per control point. In general, only a few control points should be needed for the curve (e.g. one for every 3-5 bones offers decent control).
The type of curve used does not really matter, as long as a path can be extracted from it that could also be used by the Follow Path Constraint. This really depends on the level of control required from the hooks.