Function grayscale_with_type
fn grayscale_with_type<NewPixel, I: GenericImageView>(image: &I) -> ImageBuffer<NewPixel, Vec<<NewPixel as >::Subpixel>>
where
NewPixel: Pixel + FromColor<Luma<<<I as GenericImageView>::Pixel as Pixel>::Subpixel>>
Convert the supplied image to a grayscale image with the specified pixel type. Alpha channel is discarded.