Optionaloptions: GltfExportOptions & { draco?: false }glTF 2.0 with draco: true: the same node, mesh and TRIANGLES
primitive, but the positions (plus normals, colors and UVs where present) ride
a Draco bitstream in one buffer view instead of raw buffer views. The
primitive's accessors describe the decoded shape (POSITION keeps its
min/max); extensionsUsed/extensionsRequired name the extension.
The draco3d encoder (WASM) initializes on first use; its module is shared
across calls. Needs the draco3d package installed unless dracoOptions
supplies the module or its .wasm. Reads back through
importGLTFAsync (compressed attributes beyond POSITION stay
unmapped there); the sync importGLTF still throws on it.
glTF 2.0: one node, one mesh, one TRIANGLES primitive with POSITION
(plus TEXCOORD_0 as float pairs where the mesh has UVs, NORMAL where present and COLOR_0 as normalized RGBA bytes where
the mesh is colored). Binary (default) returns a .glb; binary: false
a .gltf JSON with the buffer embedded as a base64 data URI.
Pass draco: true for KHR_draco_mesh_compression instead: the call
becomes async (a Promise<Uint8Array>), encoding through the draco3d
encoder (WASM), which lazy-loads like the decoder.
Optionaloptions: GltfExportOptions
glTF 2.0: one node, one mesh, one
TRIANGLESprimitive withPOSITION(plusTEXCOORD_0as float pairs where the mesh has UVs,NORMALwhere present andCOLOR_0as normalized RGBA bytes where the mesh is colored). Binary (default) returns a.glb;binary: falsea.gltfJSON with the buffer embedded as a base64 data URI.Pass
draco: trueforKHR_draco_mesh_compressioninstead: the call becomes async (aPromise<Uint8Array>), encoding through the draco3d encoder (WASM), which lazy-loads like the decoder.