viper_0711
hi,

thanks again for the great tools. have been testing morph for some time and built some script around it. works excellent except i encounter the following these few days and seems i'm stuck:

i finally able to reproduce the issue with simple sphere:
create morph on a sphere, add target with incoming connections. (also using "consider in mesh connection")

no problem up til here.
but when i duplicate the base object with "input connections" mode.
now maya feels slower at first. and when i look ta task manager, the CPU is non-stop. and worst. maya becomes strange e.g. i can't type in channle box value. and selection by MEL sometimes returns error etc...
save reopen the scene, same

then i checked everywhere and find that "consider in mesh connection" is the key here. if i turn it off, the CPU activity returns to zero. Or if i delete the duplicate, it return normal.

so i might conclude "consider in mesh connection" + "duplicate input connections" = nonstop CPU loading.

hope someone can help as it stop my current part of dev...


attached screen shot and sample scene . morph_report.jpg
Reply 0 0
pshipkov
This was interesting one.
So it turns out that if we have multiple objects connected to the same outputGeometry[#] attribute (the particular index), Maya forces the deformer to evaluate for each object individually.
So if you have 10 mesh objects connected to cluster1.outputGeometry[0] the cluster will evaluate 10 times instead of just one. Weird. I don't know if i can prevent that. But will investigate.
If you have frame caching turned on and in performance mode, then even for large amount of objects connected to morph.outpuGeometry[0] the performance penalty will be very small.

Now about the problem you noticed with continuous evaluation of the morph node when multiple objects are connected to its outputGeometry[0] attribute. I have some logic built-in to automatically turn-off flags that are mutually exclusive - for example if you turn-on "use inMesh connections" i have to turn-off "performance mode". If there is only one object connected to the output of the deformer then all is good. But if multiple objects - then there is a bit of cycle loop caused by MPlug called from inside the compute method manipulating attributes that force the deformer to evaluate.
This is fixed now. I am going to release new version over the weekend. Make sure you grab it before continuing with your morph related work.

Reply 0 0
viper_0711
thanks a lot Peter. much appreciated!
Reply 0 0
Reply