def __init__(self): self.info = BaseAppInfo.get() self.app = self.info.get_app() self.impl = self.info.get_app_implementation() self.mode = "all" self.session_xml = None
def __init__(my): my.info = BaseAppInfo.get() my.app = my.info.get_app() my.impl = my.info.get_app_implementation() my.mode = "all" my.session_xml = None
def set_texture_path(my, node_name, value, extra_data): import win32com.client o = win32com.client.Dispatch( "XSI.Collection" ) o.Items = node_name info = BaseAppInfo.get() # this node_name has to be uniquely identifiable in XSI if len(o) == 1: #o[0].Parameters('SourceFileName').PutValue2(0, value) source = o[0].Parameters('SourceName').GetValue2() file_range = extra_data.get('file_range') if file_range: impl = info.get_app_implementation() value = impl.get_app_file_group_path(value, file_range) my.xsi.SetValue('Sources.%s.FileName'%source, value) return True else: info.report_warning('Texture setting skipped', \ '[%s] not found. Texture path remains as checked in.' %node_name) return False '''