Esempio n. 1
0
def _to_tractor(instance,item,mel_command):
    
    file_type = instance.settings['File Types']['default'][0][0]
    module_path = os.path.dirname(instance.disk_location)
    import sys
    sys.path.append(module_path)
    import to_tractor;reload(to_tractor)
    start_frame, end_frame = _find_scene_animation_range()
    tractor = to_tractor.MayaToTractor(item)
    tractor.create_script(mel_command)
    tractor.to_tractor(start_frame,end_frame,file_type)
def _to_tractor(instance, item, mel_command):

    file_type = instance.settings['File Types']['default'][0][0]
    module_path = os.path.dirname(instance.disk_location)
    import sys
    sys.path.append(module_path)
    from imp import reload
    import to_tractor
    reload(to_tractor)
    start_frame, end_frame = _find_scene_animation_range()
    tractor = to_tractor.MayaToTractor(item)
    #if start_frame and end_frame:
    if not item.properties['name'].find("mheli_cache_grp") == -1:
        tractor.create_add_frame_script(mel_command, start_frame, end_frame)
    else:
        tractor.create_script(mel_command)
    tractor.to_tractor(start_frame, end_frame, file_type)