0
$\begingroup$

This is a question mostly for my curiosity, because I figure there's probably something I'm missing.

When I parent an object (an empty) to a bone in an armature, the object gets placed at the bone tail. (The object has the identity transform.) To the extent that the bone has a location, isn't it the bone head? So why move the child to a location that's a somewhat arbitrary distance from the bone's actual location?

And as long as we're here--what transformation space is the object in once I've done that? If I parent to another object, the child object's transformation space is relative to its parent. If I parent to a bone, is it relative to the bone's world transformation? That would be logical but I'm having trouble with it.

Thanks for any insight.

--

E.g.: I have Suzanne set up with an armature with a single bone and a single unparented Empty hanging out at the origin:

Suzanne and empty

I parent the Empty to the bone with this code:

bpy.data.objects['Empty'].parent = bpy.data.objects['Armature']
bpy.data.objects['Empty'].parent_type = 'BONE'
bpy.data.objects['Empty'].parent_bone = "Bone"

The result is the empty is moved to the bone tail position:

enter image description here

$\endgroup$
4
  • $\begingroup$ If I parent an empty to a bone, it will stay where it is and keep its location values, so I'm not sure what you mean. And it works as if you parented it to an object. Maybe show a sceenshot? $\endgroup$
    – moonboots
    Commented Jun 19, 2023 at 12:36
  • $\begingroup$ Sure, I added an example. Maybe the behavior is different if you do it through the UI? --No, just tried that and the empty moved. $\endgroup$
    – Bad Dog
    Commented Jun 19, 2023 at 13:03
  • $\begingroup$ Hey, I played around with this and confirmed what you were saying. It is weird, and I don't know why Blender's coded that way. In typical use, when you parent anything, you'll be creating an inverse at the same time that controls what the local space of the child is (including the origin of that space, whether it be at the tail or head.) Because the tail has the exact same transform as the bone as a whole, it doesn't matter to what Blender measures the inverse. But I agree, it's weird. (The object transform, in this case, is relative to the bone's local, rest orientation.) $\endgroup$
    – Nathan
    Commented Jun 19, 2023 at 14:39
  • $\begingroup$ The only thing I can guess is it's an artifact of child bones having their reference lines running to their parent's tail. But it's a PITA for me. $\endgroup$
    – Bad Dog
    Commented Jun 23, 2023 at 12:39

0

You must log in to answer this question.

Browse other questions tagged .