Lists the names of the animation groups of a loaded glTF asset container.
asset container
names of the animation groups
Starts playing an animation group of a loaded glTF asset.
animation group and playback options
Stops an animation group of a loaded glTF asset.
animation group
Gets the root transform node of a loaded glTF asset. Material variant operations require this node.
asset container
root transform node
Gets all meshes of a loaded glTF asset container.
asset container
meshes
Loads a glTF or glb file from a url into the scene and returns the asset container. The container keeps references to the meshes, materials, animation groups and the root node so that features like material variants keep working.
asset file name and root url
Babylon asset container of the loaded gltf
Loads a glTF or glb file from an uploaded asset file into the scene and returns the asset container.
asset file
Babylon asset container of the loaded glTF
Lists the names of the KHR_materials_variants material variants declared by a loaded glTF asset.
glTF root node
names of available material variants
Activates a KHR_materials_variants material variant by name, swapping the materials of the asset accordingly.
glTF root node and variant name
Gets the currently selected KHR_materials_variants material variant of a loaded glTF asset.
glTF root node
name of the selected material variant, or nothing if none is selected
Resets the materials of a loaded glTF asset back to the original KHR_materials_variants default.
glTF root node
Gets the animation groups of a loaded glTF asset container.