Skip to main content

Module color

Module color 

Source

Structs§

Color
An RGBA color value, holding four floating point components.
ColorU8
A 32-bit RGBA color value.
PremultipliedColor
A premultiplied RGBA color value, holding four floating point components.
PremultipliedColorU8
A 32-bit premultiplied RGBA color value.

Enums§

ColorSpace
The colorspace used to interpret pixel values.

Constants§

ALPHA_OPAQUE
Represents fully opaque Alpha value.
ALPHA_TRANSPARENT
Represents fully transparent Alpha value.
ALPHA_U8_OPAQUE
Represents fully opaque AlphaU8 value.
ALPHA_U8_TRANSPARENT
Represents fully transparent AlphaU8 value.
NV_ONE 🔒
NV_ZERO 🔒

Functions§

color_f32_to_u8 🔒
premultiply_u8
Return a*b/255, rounding any fractional bits.

Type Aliases§

AlphaU8
8-bit type for an alpha value. 255 is 100% opaque, zero is 100% transparent.