Get Scene Savers exampleΒΆ

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
def get_savers():
    host_svc = lx.service.Host()
    savers = []
    for x in range(host_svc.NumServers('saver')):
        factory = host_svc.ServerByIndex('saver', x)
        out_class = factory.InfoTag(lx.symbol.sSAV_OUTCLASS)
        if  (out_class == 'scene') or (out_class == 'scene2'):
            name = factory.Name()
            uname = factory.UserName()
            try:
                dostype = factory.InfoTag(lx.symbol.sSAV_DOSTYPE)
            except:
                dostype = ''
            savers.append((name, uname, dostype,))
    return savers