image

Trait PixelWithColorType

Source
pub trait PixelWithColorType: Pixel + SealedPixelWithColorType {
    const COLOR_TYPE: ColorType;
}
Expand description

The pixel with an associated ColorType. Not all possible pixels represent one of the predefined ColorTypes.

Required Associated Constants§

Source

const COLOR_TYPE: ColorType

This pixel has the format of one of the predefined ColorTypes, such as Rgb8, La16 or Rgba32F. This is needed for automatically detecting a color format when saving an image as a file.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§