PDA

View Full Version : escapable mel command?


cgcreator
09-19-2003, 01:02 AM
is there a way to create an escapable mel command.

by this i mean, when i run create a mel script that runs a proc i want the abilty to escape if i change my mind. like im using a mel script that changes out proxy geometry at render time with highres through renderman. and this takes a few mins. so if i make a mistake, i have to wait till it finishes swapping out the geometry before i can escape out of the render. i want to build in a exit command so that if i hit escape, it will break out of the mel command.

thanks

galactor
09-19-2003, 01:43 AM
You could break up the process in two parts, first maya swaps low with high res geometry. And then you could a "confirmDialog" popup that asks if you wan't to contieu rendering.

I know this it not exactly what you asked for, but as far as i know it is not possible to include an exit command in your script.

:: galactor ::

cgcreator
09-19-2003, 03:27 AM
thanks, well once it does start rendering i can escape fine just by canceling the render, its the swap that bugs me

ajk48n
09-19-2003, 06:49 AM
I'm not sure if this is possible, but what if you wrote a program in another language that would run your MEL command in batch mode from Maya to the renderer, but while it was doing the swap, it would also be loooking for keystrokes coming into the system.

wrend
09-19-2003, 07:22 AM
if the script takes it time through doing multiple commands, you can just do a check to see if some variable hasnt switched (one that you can flip from a shelf button, say) before you loop thorugh again or whatever. you can use progress bars to register a quereable escape event. if its just one big fat command that takes the time, i guess its upto whether maya supports escaping it or not.

CGTalk Moderation
01-16-2006, 04:09 AM
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.