MaterialProvider
MaterialProvider supplies materials to glTF assets during loading: the ubershader provider picks from a pre-compiled set of materials, see createUbershaderProvider.
See also
Properties
Functions
Link copied to clipboard
fun createMaterialInstance(config: MaterialKey, uvmap: UvMap, label: String? = "material", extras: String? = null): MaterialInstance?
Creates or fetches a compiled Filament material, then creates an instance from it.
Link copied to clipboard
Frees the provider itself; cached materials survive unless destroyMaterials was called.
Link copied to clipboard
Destroys all cached materials. NOT called by destroy, which lets clients take ownership of the cache if desired.
Link copied to clipboard
Creates or fetches the compiled Filament material corresponding to config, without instancing it.
Link copied to clipboard
Returns true if the given vertex attribute must be present. Some providers (e.g. ubershader) require dummy attribute values when the glTF model does not provide them.