pub struct Material {
pub name: Option<String>,
pub pbr_metallic_roughness: Option<PbrMetallicRoughness>,
pub normal_texture: Option<NormalTextureInfo>,
pub occlusion_texture: Option<OcclusionTextureInfo>,
pub emissive_texture: Option<TextureInfo>,
pub emissive_factor: Option<[f32; 3]>,
pub alpha_mode: Option<String>,
pub alpha_cutoff: Option<f32>,
pub double_sided: Option<bool>,
pub extensions: Option<MaterialExtensions>,
}Expand description
Represents a glTF material
Fields§
§name: Option<String>§pbr_metallic_roughness: Option<PbrMetallicRoughness>§normal_texture: Option<NormalTextureInfo>§occlusion_texture: Option<OcclusionTextureInfo>§emissive_texture: Option<TextureInfo>§emissive_factor: Option<[f32; 3]>§alpha_mode: Option<String>§alpha_cutoff: Option<f32>§double_sided: Option<bool>§extensions: Option<MaterialExtensions>Trait Implementations§
Source§impl<'de> Deserialize<'de> for Material
impl<'de> Deserialize<'de> for Material
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Material
impl RefUnwindSafe for Material
impl Send for Material
impl Sync for Material
impl Unpin for Material
impl UnwindSafe for Material
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian().