Module color

Source

Macrosยง

define_colors ๐Ÿ”’

Structsยง

Luma
Grayscale colors.
LumaA
Grayscale colors + alpha channel
Rgb
RGB colors.
Rgba
RGB colors + alpha channel

Enumsยง

ColorType
An enumeration over supported color types and bit depths
ExtendedColorType
An enumeration of color types encountered in image formats.

Constantsยง

SRGB_LUMA ๐Ÿ”’
Coefficients to transform from sRGB to a CIE Y (luminance) value.
SRGB_LUMA_DIV ๐Ÿ”’

Traitsยง

Blend ๐Ÿ”’
Blends a color inter another one
FromColor
Provides color conversions for the different pixel types.
FromPrimitive
Convert from one pixel component type to another. For example, convert from u8 to f32 pixel values.
IntoColor ๐Ÿ”’
Copy-based conversions to target pixel types using FromColor.
Invert ๐Ÿ”’
Invert a color

Functionsยง

normalize_float ๐Ÿ”’
rgb_to_luma ๐Ÿ”’