pub struct Layer {
pub label: String,
pub pixels: Vec<Rgba>,
pub width: u32,
pub height: u32,
pub opacity: f32,
pub blend_mode: BlendMode,
pub visible: bool,
pub z_order: i32,
}Expand description
A compositable image layer with blend settings.
Fields§
§label: String§pixels: Vec<Rgba>Pixel data in row-major order (row 0 at index 0).
width: u32§height: u32§opacity: f32Layer-wide opacity multiplier applied to each pixel’s alpha.
blend_mode: BlendMode§visible: bool§z_order: i32Compositing order; layers are sorted ascending before compositing.
Implementations§
Auto Trait Implementations§
impl Freeze for Layer
impl RefUnwindSafe for Layer
impl Send for Layer
impl Sync for Layer
impl Unpin for Layer
impl UnsafeUnpin for Layer
impl UnwindSafe for Layer
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