I’m trying to build an OSC controller to automate columns triggering in Resolume Arena. I thought about it like a tool bar to use over Arena GUI. I did the job but I have a couple of problems. The first problem is that I get an error from a dataexec "value error invalid literal for int() with base 10: ’ :0’ "
Below my code:
def onCellChange(dat, cells, prev):
table = op(’…/…/…/main/trigger_settings’)
path = op(’…/…/…/main/local/variables’)[0 , 1]
time = str(dat[0 , 0])
time = time.zfill(8)
h = time[0:2]
m = time[2:4]
s = time[4:6]
c = time[6:8]
table[path , ‘time_h’] = int(h)
table[path , ‘time_m’] = int(m)
table[path , ‘time_s’] = int(s)
table[path , ‘time_c’] = int©
dat[0 , 0] = h + ‘:’ + m + ‘:’ + s + ‘:’ + c
This function take a string that is a time input from a Field Comp and send 4 data as int in a table for subsequent processing and return a formatted string in the same Field Comp.
I have to say that despite the error everything is working good but I’d like to understand how to write better code.
The second issue is the despite the app is working good it consumes too many resources. Can you suggest any strategy to achieve better performance?