Fast Ref / API Reference / Core

export_fbx_all()

씬의 모든 레퍼런스를 지정된 폴더에 일괄 내보냅니다. 파일명은 각 레퍼런스의 네임스페이스를 기준으로 자동 생성됩니다. ({namespace}.fbx)

시그니처

api.export_fbx_all(output_folder: str, fbx_options: dict = None) -> dict

파라미터

파라미터 타입 설명
output_folder str 출력 폴더 절대 경로
fbx_options dict FBX 옵션 (생략 시 현재 기본 프리셋 사용)

반환값

{
    "success": bool,
    "message": str,
    "exported_count": int,
    "failed_count": int,
    "results": [
        {
            "slot": int,
            "name": str,
            "success": bool,
            "output_path": str,     # 성공 시
            "error": str,           # 실패 시
        },
        ...
    ]
}

예외

예외 조건
ValueError 출력 폴더가 존재하지 않을 때
TypeError fbx_optionsdict가 아닐 때

예제

import sys, os, pymxs
_p = os.path.join(pymxs.runtime.getDir(pymxs.runtime.Name("userScripts")), "os_fast_ref_package")
if _p not in sys.path: sys.path.append(_p)

from os_fast_ref.api import FastRefAPI

api = FastRefAPI()

# 기본 프리셋으로 전체 내보내기
result = api.export_fbx_all(output_folder=r"J:\output")
print(f"성공: {result['exported_count']}, 실패: {result['failed_count']}")

for r in result['results']:
    status = "OK" if r['success'] else "FAIL"
    print(f"  [{r['slot']}] {r['name']}: {status}")

💬

Need help with the API?

Open a support ticket or join the community discussion.

Contact Support