pub struct Greyscale;Expand description
Greyscale (sharp’s greyscale): every colour channel becomes the pixel’s
BT.601 luma. The channel count is kept, as in sharp, whose greyscale
output is three identical channels; alpha is untouched.
Trait Implementations§
impl Copy for Greyscale
impl Eq for Greyscale
Source§impl Op for Greyscale
impl Op for Greyscale
Source§fn rescaled(&self) -> Option<Arc<dyn Op>>
fn rescaled(&self) -> Option<Arc<dyn Op>>
A copy of this op fit for a graph rebuilt at a reduced input
resolution, or
None if this op must not be. Read moreSource§fn output_descriptor(
&self,
inputs: &[ImageDescriptor],
) -> Result<ImageDescriptor, PixelsError>
fn output_descriptor( &self, inputs: &[ImageDescriptor], ) -> Result<ImageDescriptor, PixelsError>
Compute the output shape from the input shapes. Read more
Source§fn input_regions(
&self,
output: Region,
_inputs: &[ImageDescriptor],
) -> Result<Vec<Region>, PixelsError>
fn input_regions( &self, output: Region, _inputs: &[ImageDescriptor], ) -> Result<Vec<Region>, PixelsError>
The input regions needed to produce
output. Read moreSource§fn compute(
&self,
inputs: &[Tile<'_>],
output: &mut TileMut<'_>,
) -> Result<(), PixelsError>
fn compute( &self, inputs: &[Tile<'_>], output: &mut TileMut<'_>, ) -> Result<(), PixelsError>
Source§fn access_pattern(&self) -> AccessPattern
fn access_pattern(&self) -> AccessPattern
How this op reads its inputs; drives tile negotiation (ADR-0003). Read more
impl StructuralPartialEq for Greyscale
Auto Trait Implementations§
impl Freeze for Greyscale
impl RefUnwindSafe for Greyscale
impl Send for Greyscale
impl Sync for Greyscale
impl Unpin for Greyscale
impl UnsafeUnpin for Greyscale
impl UnwindSafe for Greyscale
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