Compressed geometry and textures
Compressed geometry and textures reduce asset transfer size and can reduce GPU texture storage when the device supports the resulting format.
API​
createScenegraphsFromGLTF() consumes postprocessed loader output. Use getGLTFExtensionSupport() to inspect document capabilities and strictExtensions: true to reject unsupported required extensions before GPU scene creation. Compression decoding belongs to the loader; GPU texture upload belongs to the runtime adapter.
import {createScenegraphsFromGLTF, getGLTFExtensionSupport} from '@luma.gl/engine/gltf';
// gltf is decoded and postprocessed by @loaders.gl/scene/gltf.
for (const capability of getGLTFExtensionSupport(gltf).values()) {
console.log(capability.extensionName, capability.supportLevel);
}
const scenegraphs = createScenegraphsFromGLTF(device, gltf, {
strictExtensions: true
});
BasisU upload checks device format support. Optional unsupported formats use a fallback, while required unsupported formats fail strict checks. WebP depends on browser decoding; EXT_texture_avif source selection is unsupported by the installed glTF loader.
glTF support​
KHR_draco_mesh_compression, EXT_meshopt_compression, and KHR_meshopt_compression route through loader decoding. KHR_mesh_quantization preserves compact vertex representations. KHR_texture_basisu supplies BasisU/KTX2 texture sources; WebP source selection uses EXT_texture_webp. The embedded sample opens the Draco/KTX2 variant of ABeautifulGame.
See glTF materials and textures, glTF animation, and the extension support matrix for adapter details and current support limits.