I have been working on getting maya renders working on our farm nodes, but we need to adjust things per layer and per frame before and after.. so using vrend() in mayapy is really our only way.
We are using:
Maya 2016.5(Extension 2) SP2
Vray 3.40.06
This is a simplified version of the script we are running in mayapy, same result:
import os, sys, platform
import maya.standalone
maya.standalone.initialize(name='python')
import pymel.core as pm
from maya import cmds
cmds.file('C:/tmp/testFile.mb', o=True)
pm.currentTime(frame)
pm.setAttr("vraySettings.width", 2048 )
pm.setAttr("vraySettings.height", 858 )
pm.setAttr("vraySettings.fileNamePrefix", "TEST_Shot_L")
pm.setAttr("vraySettings.fileNamePadding", 4)
pm.setAttr("vraySettings.defaultDir", "C:/tmp/cam_L/")
The results im getting is:
2018-05-08 18:39:01: 0: STDOUT: V-Ray: Starting render
2018-05-08 18:39:01: 0: STDOUT: [2018/May/8|18:39:01] V-Ray: Exporting scene to V-Ray.
2018-05-08 18:39:01: 0: STDOUT: [2018/May/8|18:39:01] V-Ray: Parsing light links time 0h 0m 0.0s (0.0 s)
2018-05-08 18:39:01: 0: STDOUT: [2018/May/8|18:39:01] V-Ray: Total time translating scene for V-Ray 0h 0m 0.0s (0.0 s)
2018-05-08 18:39:01: 0: STDOUT: [2018/May/8|18:39:01] V-Ray: Render complete
2018-05-08 18:39:01: 0: STDOUT: [2018/May/8|18:39:01] V-Ray: ========================
2018-05-08 18:39:01: 0: STDOUT: [2018/May/8|18:39:01] V-Ray: Clearing exporter memory...
2018-05-08 18:39:01: 0: STDOUT: [2018/May/8|18:39:01] V-Ray: Total time clearing exporter memory 0h 0m 0.0s (0.0 s)
Its clearly not rendering, and not spitting out a file.. running the same command in the same file in maya.exe works as expected.
pleeeeease tell me im doing something wrong, I reeeeally need this to work in mayapy.exe not only in gui mode...
We are using:
Maya 2016.5(Extension 2) SP2
Vray 3.40.06
This is a simplified version of the script we are running in mayapy, same result:
import os, sys, platform
import maya.standalone
maya.standalone.initialize(name='python')
import pymel.core as pm
from maya import cmds
cmds.file('C:/tmp/testFile.mb', o=True)
pm.currentTime(frame)
pm.setAttr("vraySettings.width", 2048 )
pm.setAttr("vraySettings.height", 858 )
pm.setAttr("vraySettings.fileNamePrefix", "TEST_Shot_L")
pm.setAttr("vraySettings.fileNamePadding", 4)
pm.setAttr("vraySettings.defaultDir", "C:/tmp/cam_L/")
The results im getting is:
2018-05-08 18:39:01: 0: STDOUT: V-Ray: Starting render
2018-05-08 18:39:01: 0: STDOUT: [2018/May/8|18:39:01] V-Ray: Exporting scene to V-Ray.
2018-05-08 18:39:01: 0: STDOUT: [2018/May/8|18:39:01] V-Ray: Parsing light links time 0h 0m 0.0s (0.0 s)
2018-05-08 18:39:01: 0: STDOUT: [2018/May/8|18:39:01] V-Ray: Total time translating scene for V-Ray 0h 0m 0.0s (0.0 s)
2018-05-08 18:39:01: 0: STDOUT: [2018/May/8|18:39:01] V-Ray: Render complete
2018-05-08 18:39:01: 0: STDOUT: [2018/May/8|18:39:01] V-Ray: ========================
2018-05-08 18:39:01: 0: STDOUT: [2018/May/8|18:39:01] V-Ray: Clearing exporter memory...
2018-05-08 18:39:01: 0: STDOUT: [2018/May/8|18:39:01] V-Ray: Total time clearing exporter memory 0h 0m 0.0s (0.0 s)
Its clearly not rendering, and not spitting out a file.. running the same command in the same file in maya.exe works as expected.
pleeeeease tell me im doing something wrong, I reeeeally need this to work in mayapy.exe not only in gui mode...
Comment