[Bf-python] Getting armature hierarchy

Gilbert, Joseph T. jgilbert at tigr.ORG
Fri Jan 13 19:43:57 CET 2006


Lots o ways to do this.
I think that splitting these into 2 might make more sense as the user
will probably want one or the other but not both.
You can pull children like:
Bone.children[0].children for more control over hierarchy

-----Original Message-----
From: bf-python-bounces at projects.blender.org
[mailto:bf-python-bounces at projects.blender.org] On Behalf Of Stephen
Swaney
Sent: Friday, January 13, 2006 12:56 PM
To: Blender Foundation Python list
Subject: Re: [Bf-python] Getting armature hierarchy


> Subject: [Bf-python] Getting armature hierarchy
> 
> I've been keeping up to date with the Python API changes that have
been 
> taking place in Blender.  And it looks like most of the stuff needed
to 
> exported skeletal animation is available.  A while back I posted about

> the need to get the hierarchical relation of all the bones in the
> armature.
> 
> It seemed that this would be accomplished by calling the getChildren 
> method on a bone and that method would return only the immediate 
> children of the bone.  Another method named getAllChildren was
supposed 
> to provide all bones depended from the specified bone.  So far it
looks 
> like getChildren is still returning all descendants, and the purposed 
> getAllChildren method doesn't exist in the API's.

Just of the top of my head, I wonder if maybe the right way to do this
is to return a list of lists.  The first list would be the immediate
children.  The rest of the list(s) would be the remainder of the family
tree.

-- 
Stephen Swaney			


_______________________________________________
Bf-python mailing list
Bf-python at projects.blender.org
http://projects.blender.org/mailman/listinfo/bf-python



More information about the Bf-python mailing list