PDA

View Full Version : How to recognize, is the shape deforming?


iandreev
12-12-2011, 12:27 PM
Hey everyone!

I am writing a script that selects only deforming objects in the scene. And I need to recognize using Mel, Python or Maya SDK, is the object static, just transforming in time, or deforming.

Thanks.

haggi
12-12-2011, 04:40 PM
Most deforming objects have an input connection. e.g. nurbsCurves can have an input connection to the "create" attribute, meshes have one called "inMesh" and nurbsSurfaces can have a connection called "create" as well.

In your script you can check for these connections. Of course is is not guaranteed that the object is not deforming because you can modify cv's directly in an expression or scripts.

And on the other side, if this connection exists, that does not mean that the object is really deforming at all. e.g. if you create a sphere with history, you always have an input connection but the object normally does not deform until you change resolution.

iandreev
12-12-2011, 05:01 PM
I was looking for MAnimUtil::isAnimated

CGTalk Moderation
12-12-2011, 05:01 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.