Struct let_engine::Appearance
source · pub struct Appearance {
pub visible: bool,
pub material: Option<Material>,
pub data: Data,
pub transform: Transform,
pub color: [f32; 4],
}
Expand description
Holds everything about the appearance of objects like textures, vetex/index data, color and material.
Fields§
§visible: bool
§material: Option<Material>
§data: Data
§transform: Transform
§color: [f32; 4]
Implementations§
source§impl Appearance
impl Appearance
pub fn new() -> Self
pub fn new_square() -> Self
pub fn new_color(color: [f32; 4]) -> Self
pub fn auto_scale(&mut self) -> Result<(), NoTextureError>
pub fn visible(self, visible: bool) -> Self
pub fn data(self, data: Data) -> Self
pub fn transform(self, transform: Transform) -> Self
pub fn color(self, color: [f32; 4]) -> Self
pub fn material(self, material: Material) -> Self
Trait Implementations§
source§impl Clone for Appearance
impl Clone for Appearance
source§fn clone(&self) -> Appearance
fn clone(&self) -> Appearance
Returns a copy 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 Appearance
impl Debug for Appearance
source§impl Default for Appearance
impl Default for Appearance
source§impl PartialEq for Appearance
impl PartialEq for Appearance
source§fn eq(&self, other: &Appearance) -> bool
fn eq(&self, other: &Appearance) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for Appearance
Auto Trait Implementations§
impl !RefUnwindSafe for Appearance
impl Send for Appearance
impl Sync for Appearance
impl Unpin for Appearance
impl !UnwindSafe for Appearance
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
§impl<T> Pointable for T
impl<T> Pointable for T
source§impl<R, P> ReadPrimitive<R> for Pwhere
R: Read + ReadEndian<P>,
P: Default,
impl<R, P> ReadPrimitive<R> for Pwhere R: Read + ReadEndian<P>, P: Default,
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()
.