Interface IGLTFLoaderExtension
Hierarchy
- IGLTFLoaderExtension
-
IDisposable
- IGLTFLoaderExtension
Implemented by
- EXT_lights_image_based
- EXT_mesh_gpu_instancing
- EXT_meshopt_compression
- EXT_texture_webp
- ExtrasAsMetadata
- KHR_draco_mesh_compression
- KHR_lights
- KHR_materials_clearcoat
- KHR_materials_ior
- KHR_materials_pbrSpecularGlossiness
- KHR_materials_sheen
- KHR_materials_specular
- KHR_materials_translucency
- KHR_materials_transmission
- KHR_materials_unlit
- KHR_materials_variants
- KHR_mesh_quantization
- KHR_texture_basisu
- KHR_texture_transform
- KHR_xmp_json_ld
- MSFT_audio_emitter
- MSFT_lod
Index
Properties
enabledSearch playground for enabled
Defines whether this extension is enabled.
Readonly nameSearch playground for name
The name of this extension.
Optional orderSearch playground for order
Defines the order of this extension. The loader sorts the extensions using these values when loading.
Methods
Optional create MaterialSearch playground for createMaterial
-
Define this method to modify the default behavior when creating materials.
Parameters
-
context: string
The context when loading the asset
-
material: IMaterial
The glTF material property
-
babylonDrawMode: number
The draw mode for the Babylon material
Returns Nullable<Material>
The Babylon material or null if not handled
-
disposeSearch playground for dispose
-
Releases all held resources
Returns void
Optional load Animation AsyncSearch playground for loadAnimationAsync
-
Define this method to modify the default behavior when loading animations.
Parameters
-
context: string
The context when loading the asset
-
animation: IAnimation
The glTF animation property
Returns Nullable<Promise<AnimationGroup>>
A promise that resolves with the loaded Babylon animation group when the load is complete or null if not handled
-
Optional load Buffer AsyncSearch playground for loadBufferAsync
-
Define this method to modify the default behavior when loading buffers.
Parameters
-
context: string
The context when loading the asset
-
buffer: IBuffer
The glTF buffer property
-
byteOffset: number
The byte offset to load
-
byteLength: number
The byte length to load
Returns Nullable<Promise<ArrayBufferView>>
A promise that resolves with the loaded data when the load is complete or null if not handled
-
Optional load Buffer View AsyncSearch playground for loadBufferViewAsync
-
Define this method to modify the default behavior when loading buffer views.
Parameters
-
context: string
The context when loading the asset
-
bufferView: IBufferView
The glTF buffer view property
Returns Nullable<Promise<ArrayBufferView>>
A promise that resolves with the loaded data when the load is complete or null if not handled
-
Optional load Camera AsyncSearch playground for loadCameraAsync
-
Define this method to modify the default behavior when loading cameras.
Parameters
-
context: string
The context when loading the asset
-
camera: ICamera
The glTF camera property
-
assign: (babylonCamera: Camera) => void
A function called synchronously after parsing the glTF properties
-
-
Parameters
-
babylonCamera: Camera
Returns void
-
-
-
Returns Nullable<Promise<Camera>>
A promise that resolves with the loaded Babylon camera when the load is complete or null if not handled
-
Optional load Material Properties AsyncSearch playground for loadMaterialPropertiesAsync
-
Define this method to modify the default behavior when loading material properties.
Parameters
-
context: string
The context when loading the asset
-
material: IMaterial
The glTF material property
-
babylonMaterial: Material
The Babylon material
Returns Nullable<Promise<void>>
A promise that resolves when the load is complete or null if not handled
-
Optional load Node AsyncSearch playground for loadNodeAsync
-
Define this method to modify the default behavior when loading nodes.
Parameters
-
context: string
The context when loading the asset
-
node: INode
The glTF node property
-
assign: (babylonMesh: TransformNode) => void
A function called synchronously after parsing the glTF properties
-
-
Parameters
-
babylonMesh: TransformNode
Returns void
-
-
-
Returns Nullable<Promise<TransformNode>>
A promise that resolves with the loaded Babylon transform node when the load is complete or null if not handled
-
Optional load Scene AsyncSearch playground for loadSceneAsync
Optional load Texture Info AsyncSearch playground for loadTextureInfoAsync
-
Define this method to modify the default behavior when loading texture infos.
Parameters
-
context: string
The context when loading the asset
-
textureInfo: ITextureInfo
The glTF texture info property
-
assign: (babylonTexture: BaseTexture) => void
A function called synchronously after parsing the glTF properties
-
-
Parameters
-
babylonTexture: BaseTexture
Returns void
-
-
-
Returns Nullable<Promise<BaseTexture>>
A promise that resolves with the loaded Babylon texture when the load is complete or null if not handled
-
Optional on LoadingSearch playground for onLoading
-
Called after the loader state changes to LOADING.
Returns void
Optional on ReadySearch playground for onReady
-
Called after the loader state changes to READY.
Returns void
Interface for a glTF loader extension.