Struct Luma

struct Luma<T>(3268)

Grayscale colors.

Implementations

impl PixelWithColorType for Luma<u16>

impl PixelWithColorType for Luma<u8>

impl<T> Any for Luma<T>

fn type_id(self: &Self) -> TypeId

impl<T> Borrow for Luma<T>

fn borrow(self: &Self) -> &T

impl<T> BorrowMut for Luma<T>

fn borrow_mut(self: &mut Self) -> &mut T

impl<T> CloneToUninit for Luma<T>

unsafe fn clone_to_uninit(self: &Self, dest: *mut u8)

impl<T> Freeze for Luma<T>

impl<T> From for Luma<T>

fn from(t: T) -> T

Returns the argument unchanged.

impl<T> From for Luma<T>

fn from(c: [T; 1]) -> Self

impl<T> Index for Luma<T>

fn index(self: &Self, _index: usize) -> &T

impl<T> IndexMut for Luma<T>

fn index_mut(self: &mut Self, _index: usize) -> &mut T

impl<T> Pointable for Luma<T>

unsafe fn init(init: <T as Pointable>::Init) -> usize
unsafe fn deref<'a>(ptr: usize) -> &'a T
unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T
unsafe fn drop(ptr: usize)

impl<T> RefUnwindSafe for Luma<T>

impl<T> Send for Luma<T>

impl<T> StructuralPartialEq for Luma<T>

impl<T> Sync for Luma<T>

impl<T> ToOwned for Luma<T>

fn to_owned(self: &Self) -> T
fn clone_into(self: &Self, target: &mut T)

impl<T> Unpin for Luma<T>

impl<T> UnsafeUnpin for Luma<T>

impl<T> UnwindSafe for Luma<T>

impl<T, U> Into for Luma<T>

fn into(self: Self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

impl<T, U> TryFrom for Luma<T>

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

impl<T, U> TryInto for Luma<T>

fn try_into(self: Self) -> Result<U, <U as TryFrom<T>>::Error>

impl<T: $crate::clone::Clone> Clone for Luma<T>

fn clone(self: &Self) -> Luma<T>

impl<T: $crate::cmp::Eq> Eq for Luma<T>

impl<T: $crate::cmp::PartialEq> PartialEq for Luma<T>

fn eq(self: &Self, other: &Luma<T>) -> bool

impl<T: $crate::fmt::Debug> Debug for Luma<T>

fn fmt(self: &Self, f: &mut Formatter<'_>) -> Result

impl<T: $crate::hash::Hash> Hash for Luma<T>

fn hash<__H: $crate::hash::Hasher>(self: &Self, state: &mut __H)

impl<T: $crate::marker::Copy> Copy for Luma<T>

impl<T: Primitive> Pixel for Luma<T>

fn channels(self: &Self) -> &[T]
fn channels_mut(self: &mut Self) -> &mut [T]
fn channels4(self: &Self) -> (T, T, T, T)
fn from_channels(a: T, b: T, c: T, d: T) -> Luma<T>
fn from_slice(slice: &[T]) -> &Luma<T>
fn from_slice_mut(slice: &mut [T]) -> &mut Luma<T>
fn to_rgb(self: &Self) -> Rgb<T>
fn to_rgba(self: &Self) -> Rgba<T>
fn to_luma(self: &Self) -> Luma<T>
fn to_luma_alpha(self: &Self) -> LumaA<T>
fn map<F>(self: &Self, f: F) -> Luma<T>
where
    F: FnMut(T) -> T
fn apply<F>(self: &mut Self, f: F)
where
    F: FnMut(T) -> T
fn map_with_alpha<F, G>(self: &Self, f: F, g: G) -> Luma<T>
where
    F: FnMut(T) -> T,
    G: FnMut(T) -> T
fn apply_with_alpha<F, G>(self: &mut Self, f: F, g: G)
where
    F: FnMut(T) -> T,
    G: FnMut(T) -> T
fn map2<F>(self: &Self, other: &Self, f: F) -> Luma<T>
where
    F: FnMut(T, T) -> T
fn apply2<F>(self: &mut Self, other: &Luma<T>, f: F)
where
    F: FnMut(T, T) -> T
fn invert(self: &mut Self)
fn blend(self: &mut Self, other: &Luma<T>)