Reputation: 80
So basically I am trying to open maya from command line using subprocess in python and executing a python script (.py) file like below:
command = [
"C:/Program Files/Autodesk/Maya2020/bin/maya.exe",
'-command',
'python("exec('python script path")'
]
from my script everything is working fine like maya is opening and as well the file except one command for example:
mel.eval('renderSequenceOptionsWindow;')
mel.eval('optionMenuGrp -e -v "{}" renderSequenceCameraList;'.format(facial_cam_node))
mel.eval('renderSequenceCurrentCameraChanged();')
mel.eval('renderSequence;')
I have these commands first three are working fine except the last one , the issue is I am not getting an error as well, its like Maya is not even considering this command from the script.
facial_cam_node
> is the camera I'll be using to render images.And the weird part is on the same opened Maya session ( which I opened from command line), when I am running this command back again in script editor then its rendering as well, its just not happening in the automated workflow.
Any help would be great thanks
Upvotes: 0
Views: 118