pub trait RaylibMaterial: AsRef<Material> + AsMut<Material> {
// Provided methods
fn shader(&self) -> &WeakShader { ... }
fn shader_mut(&mut self) -> &mut WeakShader { ... }
fn maps(&self) -> &[MaterialMap] { ... }
fn maps_mut(&mut self) -> &mut [MaterialMap] { ... }
fn set_material_texture(
&mut self,
map_type: MaterialMapIndex,
texture: impl AsRef<Texture>,
) { ... }
fn is_material_valid(&mut self) -> bool { ... }
}Provided Methods§
fn shader(&self) -> &WeakShader
fn shader_mut(&mut self) -> &mut WeakShader
fn maps(&self) -> &[MaterialMap]
fn maps_mut(&mut self) -> &mut [MaterialMap]
fn set_material_texture( &mut self, map_type: MaterialMapIndex, texture: impl AsRef<Texture>, )
fn is_material_valid(&mut self) -> bool
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.