Function rend3_gltf::load_materials_and_textures
source · [−]pub async fn load_materials_and_textures<F, Fut, E>(
renderer: &Renderer,
materials: impl ExactSizeIterator<Item = Material<'_>>,
buffers: &[Vec<u8>],
settings: &GltfLoadSettings,
io_func: &mut F
) -> Result<(Vec<Labeled<MaterialHandle>>, ImageMap), GltfLoadError<E>> where
F: FnMut(SsoString) -> Fut,
Fut: Future<Output = Result<Vec<u8>, E>>,
E: Error + 'static,
Expand description
Loads materials and textures from a gltf::Material
iterator.
All binary data buffers must be provided. Call this with
gltf::Document::materials
as the materials argument.
io_func determines how URIs are resolved into their underlying data.