user: What is Parenting and how is it used in Blender Python scripting?

assistant: Parent
:   A [Data ID](../../../../interface/controls/templates/data_block.html#ui-data-id) to select the bone to set as a parent.

Relative Parenting Pose Mode Only
:   Changes how transformation of the bone is applied to its child Objects.

Connected
:   The *Connected* checkbox set the head of the bone to be connected with its parent root.

### Transformations

Bones relationships have effects on transformations behavior.

By default, children bones inherit:

- Their parent position, with their own offset of course.
- Their parent rotation (i.e. they keep a constant rotation relatively to their parent).
- Their parent scale, here again with their own offset.

Examples of transforming parented/connected bones.

|  |  |  |
| --- | --- | --- |
| <../../../../_images/animation_armatures_bones_properties_relations_rest.png>   The armature in its rest position. | <../../../../_images/animation_armatures_bones_properties_relations_root-rotation.png>   Rotation of a root bone. | <../../../../_images/animation_armatures_bones_properties_relations_root-scale.png>   Scaling of a root bone. |

Exactly like standard children objects. You can modify this behavior on a per-bone basis,
using the Relations panel in the *Bones* tab:

Local Location
:   When disabled, the location transform property is evaluated in the parent bone’s local space,
    rather than using the bone’s own *rest pose* local space orientation.

Inherit Rotation
:   When disabled, this will “break” the rotation relationship to the bone’s parent.
    This means that the child will keep its rotation in the armature object space when its parent is rotated.

Inherit Scale
:   Specifies which effects of parent scaling the bone inherits:

    These inheriting behaviors propagate along the bones’ hierarchy.
    So when you scale down a bone, all its descendants are by default scaled down accordingly.
    However, if you disable one bone’s *Inherit Scale* or *Inherit Rotation*
    property in this “family”, this will break the scaling propagation,
    i.e. this bone *and all its descendants* will no longer be affected when you scale one of its ancestors.

    Full:
    :   The bone inherits all effects of parent scaling and shear.

    Fix Shear:
    :   Full parent effects are applied to the rest state of the child, after which any shear is
        removed in a way that preserves the bone direction, length and volume, and minimally affects
        roll on average. The result is combined with the local transformation of the child.

        If the inherited scale is non-uniform, this does not prevent shear from reappearing due to
        local rotation of the child bone, or of its children.

    Aligned:
    :   Parent scaling is inherited as if the child was oriented the same as the parent, always
        applying parent X scale over child X scale, and so on.

    Average:
    :   Inherits a uniform scaling factor that is the total change in the volume of the parent.

    None:
    :   Ignores all scaling and shear of the parent.

    None (Legacy):
    :   Ignores all scaling, provided the parent is not sheared. If it is, there are no guarantees.

        This choice replicates the behavior of the old Inherit Scale checkbox, and may be removed in a future release.

    Examples of transforming parented/connected bones with Inherit Rotation disabled.

    |  |  |  |
    | --- | --- | --- |
    | ../../../../_images/animation_armatures_bones_properties_relations_inherit-rot-disabled.png   The yellow outlined Inherit Rotation disabled bone in the armature. | ../../../../_images/animation_armatures_bones_properties_relations_inherit-rot-disabled-descendant.png   Rotation of a bone with an Inherit Rotation disabled bone among its descendants. | ../../../../_images/animation_armatures_bones_properties_relations_inherit-rot-disabled-scale.png   Scaling of a bone with an Inherit Rotation disabled bone among its descendants. |

Connected bones have another specificity: they cannot be moved. Indeed,
as their root must be at their parent’s tip, if you do not move the parent,
you cannot move the child’s root, but only its tip, which leads to a child rotation.
This is exactly what happens, when you press `G` with a connected bone selected,
Blender automatically switches to rotation operation.

Bones relationships also have important consequences on how selections of multiple bones
behave when transformed. There are many different situations which may not be included on this list,
however, this should give a good idea of the problem:

- Non-related selected bones are transformed independently, as usual.
- When several bones of the same “family” are selected,
  *only* the “most parent” ones are really transformed –
  the descendants are just handled through the parent relationship process, as if they were not selected
  (see Fig. [Scaling bones, some of them related.](#fig-rig-pose-edit-scale) the third tip bone,
  outlined in yellow, was only scaled down through the parent relationship,
  exactly as the unselected ones, even though it is selected and active.
  Otherwise, it should have been twice smaller!)

  [[image reference removed]](../../../../_images/animation_armatures_bones_properties_relations_scale-related.png)

  Scaling bones, some of them related.
- When connected and unconnected bones are selected,
  and you start a move operation, only the unconnected bones are affected.
- When a child connected hinge bone is in the selection,
  and the “most parent” selected one is connected, when you press `G`,
  nothing happens, because Blender remains in move operation, which of course has no effect on a connected bone.

So, when posing a chain of bones, you should always edit its elements from the root bone to the tip bone.
This process is known as [Forward Kinematics](../../../../glossary/index.html#term-Forward-Kinematics) (FK).
We will see in a [later page](../../posing/bone_constraints/inverse_kinematics/introduction.html#bone-constraints-inverse-kinematics)
that Blender features another pose method, called [Inverse Kinematics](../../../../glossary/index.html#term-Inverse-Kinematics) (IK),
which allows you to pose a whole chain just by moving its tip.