Adding custom deformer to a skinned mesh

18 views
Skip to first unread message

Utkarsh Agnihotri

unread,
Jul 5, 2021, 7:47:36 AM7/5/21
to Python Programming for Autodesk Maya
Hi, everyone,
I am trying to write a custom deformer and it is working well with single mesh with no inputs like skincluster, blendshape, wrap deformer etc. But when I try to run it on a mesh with multiple deformers, it throws me a cycle warning. Can you please tell me how can I avoid this in maya api?

Thanks!!

Marcus Ottosson

unread,
Jul 5, 2021, 8:24:31 AM7/5/21
to python_in...@googlegroups.com

Cycle warnings come from the way nodes are connected, rather than the API (assuming you mean maya.api.OpenMaya or the C++ API?). The warning means that one or more output attributes in your plug-in is causing one or more of the of the input attributes to evaluate. For example, if the mesh.outMesh is connected to yourDeformer.inMesh and yourDeformer.outMesh is connected to mesh.inMesh, that would be a cycle if inMesh is used to compute outMesh. I would disconnect all of them, and reconnect each of them one at a time until the warning makes an appearance. You can also comment-out all of your attributeAffects() calls, which is what determines which plug should cause another plug to evaluate.


--
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 python_inside_m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/5437b6d1-aa9f-4639-852a-0738f539240dn%40googlegroups.com.

Utkarsh Agnihotri

unread,
Jul 5, 2021, 8:30:06 AM7/5/21
to Python Programming for Autodesk Maya
Hi Marcus,
Thanks for the reply.
I am using python maya api 1.0 .
The problem is that I am not able to anything because scene crashes so it's hard to test through connections. I will try using attributeAffects. 
I am trying to effect the mesh based on intersection by using closestIntersection , so there is no secondary output. Is it a good way to operate on the source mesh?
Reply all
Reply to author
Forward
0 new messages