로더 state
지원 포맷
내부 GLTFLoader 접근
LoadingManager 접근
BVH 활성화 여부
Worker Pool 병렬 로딩 지원 여부
Whether the overlapped File API import path is enabled. File API 오버랩 임포트 경로 활성화 여부입니다.
Whether THREE.Cache injection for BIN buffers is enabled. BIN 버퍼에 대한 THREE.Cache 주입 활성화 여부입니다.
Runtime toggle for the loadOptimized BIN handling. When true, BIN
ArrayBuffers are injected into THREE.Cache and resolved without object
URLs or re-fetch. When false, the legacy Blob URL round-trip is used.
loadOptimized의 BIN 처리 런타임 토글. true이면 BIN ArrayBuffer를
THREE.Cache에 주입하여 object URL/재fetch 없이 해석하고, false이면
기존 Blob URL 왕복 경로를 사용합니다.
Whether worker-based GLTF/GLB parsing is enabled. Worker 기반 GLTF/GLB 파싱 활성화 여부입니다.
When enabled, the loadOptimized path offloads parsing to a Worker pool.
For GLB it parses the buffer directly; for external-resource GLTF it packs
an in-memory GLB (GLBPacker) first. Inputs that the lightweight worker
parser cannot handle (compression/skin/morph/sparse) silently fall back to
the main thread with byte-identical results. When false, parsing always
runs on the main thread.
활성화 시 loadOptimized 경로는 파싱을 Worker 풀로 오프로딩합니다. GLB는
버퍼를 직접 파싱하고, 외부 리소스 GLTF는 먼저 in-memory GLB(GLBPacker)로
팩합니다. 경량 worker 파서가 처리할 수 없는 입력(압축/스킨/morph/sparse)은
바이트 단위로 동일한 결과로 조용히 메인스레드로 폴백합니다. false이면
파싱은 항상 메인스레드에서 실행됩니다.
Whether the worker/main-thread 1:1 parse comparison mode is enabled. worker/메인스레드 1:1 파싱 비교 모드 활성화 여부입니다.
Debug-only (design §4.3). When enabled and the worker path is taken, the same packed GLB is also parsed on the main thread and the two results (mesh count, vertex count, material count, animation count) are compared, logging a mismatch. The main-thread result is preserved as the source of truth. Default off; intended for fidelity verification, not production. 디버그 전용(설계 §4.3). 활성화 후 worker 경로를 타면 동일한 팩 GLB를 메인스레드에서도 파싱하여 두 결과(메시 수/정점 수/머티리얼 수/애니메이션 수)를 비교하고 불일치를 로깅합니다. 메인스레드 결과를 진실의 원천으로 유지합니다. 기본 off이며, 충실도 검증용입니다.
Whether the worker-loading PoC decode path is enabled. 워커 로딩 PoC 디코드 경로 활성화 여부입니다.
Stage-2 PoC gate (workerLoadPoC, design §7). When enabled, up to a small
cap of representative external-resource GLTF files are decoded on a robust
LoadWorkerPool and assembled on the main thread; the rest and any
unsupported/failed input fall back to main-thread parseAsync losslessly.
When false, behavior is completely unchanged. Not for production.
2단계 PoC 게이트(workerLoadPoC, 설계 §7). 활성화 시 소수 대표 외부 리소스
GLTF 파일을 견고 LoadWorkerPool에서 디코드하고 메인스레드에서 조립합니다.
나머지와 미지원/실패 입력은 메인스레드 parseAsync로 무손실 폴백합니다.
false이면 동작이 완전히 불변입니다. 운영 비권장.
Returns the current material dedup statistics. 현재 머티리얼 중복 제거 통계를 반환합니다.
Stats with before (distinct instances) and after (unique canonicals);
dedup이 비활성이면 { before: 0, after: 0 }.
before(서로 다른 인스턴스 수)와 after(고유 대표 수)를 담은 통계.
URL이 지원되는 포맷인지 확인
URL 또는 파일명
Returns the accumulated loadOptimized phase timings and call count.
누적된 loadOptimized phase 타이밍과 호출 수를 반환합니다.
Object with summed per-phase milliseconds and count of calls.
phase별 누적 밀리초 합과 호출 수(count)를 담은 객체.
Returns the accumulated synchronous-CPU vs I/O-wait profile of loadOptimized.
loadOptimized의 누적 동기 CPU 대 I/O 대기 프로파일을 반환합니다.
Object with summed per-span milliseconds (spans) and count of calls
구간별 누적 밀리초(spans)와 호출 수(count)를 담은 객체
워커 로딩 파이프라인 1단계(설계 §7)의 핵심 계측입니다. phase 합(동시성 대기로
부풀려진 값)이 아니라, 메인스레드에서 소비된 구간을 성격별로 분리합니다:
jsonParse/binArrayBuffer/cacheInject/gltfStringify/gltfParse/geomWrap는
동기 CPU(워커 이관 후보), binReadIO는 fetch 등 async I/O 대기(워커 무관)입니다.
gltfParse는 GLTFLoader.parse의 동기 accessor 디코드와 텍스처 등 async가 섞인
wall이며, 완전 분리가 불가하므로 동기 근사(upper bound) 로 간주합니다(정직성
주석). 이 모델은 Textures=0이라 async 비중이 작다고 가정합니다. 정확한 동기
self-time은 Chrome Performance User Timing 마커 대조로 확인하십시오.
Core step-1 instrumentation (design §7). Splits main-thread spans by nature
instead of the concurrency-inflated phase sums. binReadIO is async I/O wait
(worker-irrelevant); all other keys are synchronous CPU (worker-offload
candidates). gltfParse mixes synchronous accessor decode with async
(textures) and is treated as a synchronous upper-bound approximation.
GLTF/GLB 파일 load
파일 URL (일반 URL 또는 Blob URL)
Optionalfilename: string원본 파일명 (Blob URL인 경우 포맷 감지용)
파일 그룹으로 GLTF 로드
GLTF/GLB 메인 파일
관련 파일 목록 (bin, 텍스처 포함)
GLTF 로드 결과
Loads a GLTF/GLB file group through the overlapped optimized path. 오버랩 최적화 경로로 GLTF/GLB 파일 그룹을 로드합니다.
GLTF/GLB main file GLTF/GLB 메인 파일
Related file list (bin, textures) 관련 파일 목록 (bin, 텍스처 포함)
GLTF load result GLTF 로드 결과
단계 ① 구현 (worker 미사용). 동작 흐름:
_fileContentCache/_externalFileUrlMap을 채운 뒤 메인스레드 loadOptimized로 위임어떤 단계에서든 실패하면 기존 loadWithFiles 경로로 폴백하여 동일한 결과를
보장합니다. 외부 BIN을 메인스레드에서 직접 읽으므로 worker fetch의 blob URL
제약을 우회하며, 오버랩으로 직렬 대기를 줄입니다.
ArrayBuffer에서 직접 GLTF 파싱
GLTF/GLB ArrayBuffer
리소스 해석을 위한 기본 경로
GLTF 로드 결과
외부 파일 URL 맵 설정 (BIN, 텍스처 등)
파일명 → Blob URL 맵
외부 파일 URL 맵 초기화
파일 콘텐츠 캐시에 추가 (Blob URL fetch 우회용)
Blob URL
파일 콘텐츠 (ArrayBuffer)
파일 콘텐츠 캐시 일괄 추가
Blob URL → ArrayBuffer 맵
파일 콘텐츠 캐시 초기화
Sets the external resource file handles for the worker-load PoC v2 path. 워커 로딩 PoC v2 경로용 외부 리소스 파일 핸들을 설정합니다.
Lowercased file name to file handle 소문자 파일명 → 파일 핸들
PoC v2 핵심 배선. 키는 외부 리소스 파일명(소문자), 값은 FileSystemFileHandle
입니다. _tryWorkerLoadPoC가 gltf JSON의 외부 buffer/image uri를 이 맵에서
해석하여 워커로 핸들을 전달하고, 워커가 handle.getFile()→arrayBuffer()로
바이트를 직접 읽습니다(메인에서 bin ArrayBuffer를 읽지 않음 → 복사·OOM 원천 제거).
PoC v2 wiring. Keys are lowercased external resource file names; values are
FileSystemFileHandles. _tryWorkerLoadPoC resolves the gltf JSON external
buffer/image uris against this map and posts the handles to the worker, which
reads the bytes itself (the main thread never reads bin ArrayBuffers → the
copy/OOM source is removed).
외부 리소스 파일 핸들 맵 초기화
Sets the model cache for HTTP URL caching. HTTP URL 캐싱을 위한 모델 캐시를 설정합니다.
Model cache instance 모델 캐시 인스턴스
Worker Pool 병렬 로딩으로 GLTF 로드
GLTF/GLB 파일 URL
OptionalonProgress: (progress: ParallelLoadProgress) => void진행률 콜백
GLTF 로드 결과
Worker Pool 활성화 (런타임)
OptionalworkerCount: numberWorker 수 (기본: CPU 코어 수 기반)
Worker Pool 비활성화
Sets the WebGLRenderer for KTX2 GPU format detection. KTX2 GPU 포맷 감지를 위한 WebGLRenderer를 설정합니다.
WebGLRenderer instance WebGLRenderer 인스턴스
DRACO 로더 config (런타임)
리소스 cleanup
GLTFLoaderWrapper - GLTF/GLB 파일 로더
Three.js GLTFLoader를 래핑하여 통일된 interface를 제공합니다.
Remarks
Example