# me - this DAT
# scriptOp - the OP which is cooking
#
targets_pars_vals = [
[ 'tex3d1', 'cachesize', 1 ],
[ 'ramp3', 'resolutionh', 1 ],
[ 'tima1', 'blackoffset', -1 ]
]
# press 'Setup Parameters' in the OP to call this function to re-create the parameters.
def setupParameters(scriptOp):
page = scriptOp.appendCustomPage('Spiral Settings')
p = page.appendInt('Depth', label='Depth')
return
# called whenever custom pulse parameter is pushed
def onPulse(par):
return
def cook(scriptOp):
scriptOp.clear()
# set up header row
header = [ 'path', 'parameter', 'value', 'enable' ]
# add header row
scriptOp.appendRow(header)
# add targs_pars_vals
for each_target in targets_pars_vals:
new_row = [each_target[0], each_target[1], each_target[2] * scriptOp.par.Depth, 1 ]
scriptOp.appendRow(new_row)
return