pub struct SpriteMaterial {
pub base_texture: String,
pub surface_prop: Option<String>,
pub sprite_orientation: SpriteOrientation,
pub sprite_origin: Vec2,
pub color: Vec3,
pub alpha: f32,
pub alpha_test: bool,
pub alpha_test_reference: f32,
pub translucent: bool,
}Fields§
§base_texture: StringDefines an albedo texture.
surface_prop: Option<String>Links the surface to a set of physical properties.
sprite_orientation: SpriteOrientation§sprite_origin: Vec2§color: Vec3Independently scales the red, green and blue channels of an albedo.
alpha: f32Scales the opacity of an entire material.
alpha_test: boolSpecifies a mask to use to determine binary opacity.
alpha_test_reference: f32Specifies a mask to use to determine binary opacity.
translucent: boolSpecifies that the material should be partially see-through.
Trait Implementations§
Source§impl Clone for SpriteMaterial
impl Clone for SpriteMaterial
Source§fn clone(&self) -> SpriteMaterial
fn clone(&self) -> SpriteMaterial
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SpriteMaterial
impl Debug for SpriteMaterial
Source§impl<'de> Deserialize<'de> for SpriteMaterial
impl<'de> Deserialize<'de> for SpriteMaterial
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 SpriteMaterial
impl RefUnwindSafe for SpriteMaterial
impl Send for SpriteMaterial
impl Sync for SpriteMaterial
impl Unpin for SpriteMaterial
impl UnwindSafe for SpriteMaterial
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