Batch rendering with Syflex?


#1

Hi all,
I was wondering if anyone has had any experience with running non-gui Syflex simulations, for example on a farm machine. If I understand correctly it is possible to use the cpRunBatch script for launching maya cloth simulations in batch mode, but are there examples for doing the same with a syflex simulation?

Thanks.

#2

ya,
to guarantee cloth is solved, each frame
within the frame loop, query the the bounding box of the cloth mesh

getAttr ($shape[0]+".boundingBoxMinX");

like,

string $listSySolvers[]= `ls -typ syCloth`;

for ($frame = ($start); $frame <= ($end + 1); $frame++){
    $sy_timer = `timerX`;
    currentTime -e $frame;

    for($solver in $listSySolvers){
        if(!`getAttr  -l  ($solver+".cacheName")`){
            string $shape[] = `listConnections -sh 1 ($solver+".outMesh")`;
                while (`nodeType $shape[0]` != "mesh") {
                    string $node = $shape[0];
                    $shape = `listConnections -sh 1 ($node+".outputGeometry")`;
                }
                getAttr  ($shape[0]+".boundingBoxMinX");           
            }
        }


    int $sy_roundTime = `timerX -st $sy_timer`;
    print ($fileName1+": frame " + $frame + " took syflex " + ($sy_roundTime) + " seconds.

");
}


#3

So do I need to substitute this piece of code into the cpRunBatch script to make it applicable to syflex or write an entirely new script to handle the syflex simulation?
My MEL experience is fairly limited so any help pointing me in the right direction would be appreciated.

Thanks.


#4

well sort of , you would also need to make sure the syCloth cache attr is properly set…

r u useing linux? or windoz…

Another way to make syCloth solve in batch mode is to make sure it is within the rendering camera
view and that the cloth is renderable, and that the cache attr is pointing to a directory/file
that does not have cache , ( or it will just use the cache that it is pointing too)

I’m a bit supprised that there is not scripts widely avialable to windoz or linux users to batch solver Syflex…

I have linux scripts that will force batch solve, with or without rendering…
but I’m not going to convert them to deal with windoz… :slight_smile:


#5

I’m running linux. I also thought that scripts for batching syflex sims, or at least some info on it would be more widely available. I suppose someone’s trying to tell me to improve on my lack of mel scripting. :slight_smile:


#6

here’s a no frils linux syflex batch script
see the tail of the file for usage


#7

Sorry for the delay in posting, have been away.
Will take a look at this, many thanks for your help.


#8

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.