ApplyTransform

Trait ApplyTransform 

Source
pub trait ApplyTransform<Pix: Pixel, F> {
    type CombinedTransform: PixelTransform<Pix>;

    // Required method
    fn apply(
        self,
        transform: F,
    ) -> ImageAndTransform<Pix, Self::CombinedTransform>;
}
Expand description

Trait allowing to lazily apply one or more PixelTransforms to an image.

This trait is implemented for ImageBuffers and for ImageAndTransforms, allowing to chain transforms.

Required Associated Types§

Source

type CombinedTransform: PixelTransform<Pix>

Combined transform after applying transform.

Required Methods§

Source

fn apply(self, transform: F) -> ImageAndTransform<Pix, Self::CombinedTransform>

Appends transform to the list of transforms to be performed on the source image.

Implementations on Foreign Types§

Source§

impl<Pix, F> ApplyTransform<Pix, F> for ImageBuffer<Pix, Vec<Pix::Subpixel>>
where Pix: Pixel, F: PixelTransform<Pix>,

Source§

type CombinedTransform = F

Source§

fn apply(self, transform: F) -> ImageAndTransform<Pix, F>

Implementors§

Source§

impl<Pix, F, G> ApplyTransform<Pix, G> for ImageAndTransform<Pix, F>
where Pix: Pixel, F: PixelTransform<Pix>, G: PixelTransform<F::Output>,