pub enum MaskMode {
Alpha,
InvertedAlpha,
Luminance,
InvertedLuminance,
}Expand description
How linear-premultiplied content becomes a layer’s mask coverage.
Coverage is computed in the compositing color space and clamped to 0..=1 before optional inversion, without altering working colors. Alpha-zero pixels have zero ordinary coverage, even with hidden extended RGB; inverted modes therefore retain source content at those pixels.
Variants§
Alpha
Use only the completed mask’s alpha.
InvertedAlpha
One minus the completed mask’s alpha, including transparent artwork.
Luminance
Use Rec.709 luminance of linear premultiplied RGB, already alpha-weighted.
InvertedLuminance
One minus clamped linear-premultiplied luminance; alpha is not inverted first.
Trait Implementations§
impl Copy for MaskMode
impl Eq for MaskMode
impl StructuralPartialEq for MaskMode
Auto Trait Implementations§
impl Forget for MaskMode
impl Freeze for MaskMode
impl Move for MaskMode
impl RefUnwindSafe for MaskMode
impl Send for MaskMode
impl Sync for MaskMode
impl Unpin for MaskMode
impl UnsafeUnpin for MaskMode
impl UnwindSafe for MaskMode
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