I would suggest looking into using the listHistory command to get back the
history nodes of type anim curve

On Wednesday, March 23, 2016, Lidia Martinez <[email protected]> wrote:

> Hi all!,
>
> animLayers python command is pretty bad in general. Docs are wrong, for
> most of the params. I sent suggestions to Autodesk. They normally fix it...
> but it's annoying.
>
>
> I want to find the animation curves for an node. If it happens to be
> inside an anim layer... the party starts:
>
>
>
> The problem is I only have these options:
>
> A) mc.animLayer( layer, animCurves=True, q=1)
> B) mc.animLayer( [object], affectedLayers=True, q=1)
> C) mc.animLayer( layer, blendNodes=True, q=1)
>
> A)  Returns ALL THE ANIM CURVES for ALL CHANNELS for ALL OBJECTS in the
> scene.  (????  insane).  They can be thousands of strings.
>
> B)  It returns which layers the object is in.
> NOTE: the docs don't tell you about that list... weird.
>
> C)  Gets the blending nodes FOR ALL CHANNELS for ALL OBJECTS in that
> layer. These ones connect the animations and the original node. They can be
> hundreds.
>
> So that's all I have...
>
> Crazy stuff. I get a list of 5000 strings. And we all know how fast
> strings are. And considering how python manages memory in terms of growing
> lists and then deleting the contents...
>
> And I have to do that... for every object I have.
>
>
>
>
> I'll end up using my stupid algorithm that travels through the blend nodes
> to find the animations... which is obviously buggy, too, and has special
> cases everywhere.
>
>
>
>
> Any ideas?
>
> --
> Lidia
>
> --
> You received this message because you are subscribed to the Google Groups
> "Python Programming for Autodesk Maya" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected]
> <javascript:_e(%7B%7D,'cvml','python_inside_maya%[email protected]');>
> .
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/python_inside_maya/CAAB1%3D8yTd7L-fxAUmMoOGUcYBzVBpTZxo%2B1FX0LeLM%3DXtte_7g%40mail.gmail.com
> <https://groups.google.com/d/msgid/python_inside_maya/CAAB1%3D8yTd7L-fxAUmMoOGUcYBzVBpTZxo%2B1FX0LeLM%3DXtte_7g%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/python_inside_maya/CAM9RXoLjRDcvObEXVqLiOYOCPmmid9o6W1AWsv%3DpQeyAJCyV0w%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to