Skip to content

Commit

Permalink
Overscan tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
sosoyan committed Aug 29, 2016
1 parent 30b1e04 commit d34d374
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions scripts/aton_maya.py
Original file line number Diff line number Diff line change
Expand Up @@ -493,25 +493,26 @@ def getRegion(self, attr, resScale = True):

def setOverscan(self):
ovrScnValue = bool(self.overscanSpinBox.value())
message = "Do you want to set the Overscan values in Render Setttings? "
if cmds.getAttr("defaultRenderGlobals.ren") == "arnold" and ovrScnValue:
if cmds.getAttr("defaultRenderGlobals.ren") == "arnold":
message = "Do you want to set the Overscan values in Render Setttings?"
result = cmds.confirmDialog(title='Overscan',
message=message,
button=['OK', 'Cancel'],
defaultButton='OK',
cancelButton='Cancel',
dismissString='Cancel',
icn="information")

if result == 'OK':
rMinX = self.getRegion(2, False)
rMinY = self.getRegion(3, False)
rMaxX = self.getRegion(4, False)
rMaxY = self.getRegion(5, False)
cmds.setAttr("defaultArnoldRenderOptions.outputOverscan", "%s %s %s %s"%(rMinX,
rMinY,
rMaxX,
rMaxY), type="string")
attr = "defaultArnoldRenderOptions.outputOverscan"
if ovrScnValue:
cmds.setAttr(attr, "%s %s %s %s"%(rMinX, rMinY, rMaxX, rMaxY), type="string")
else:
cmds.setAttr(attr, "", type="string")


def getNukeCropNode(self, *args):
''' Get crop node data from Nuke '''
Expand Down

0 comments on commit d34d374

Please sign in to comment.