Skip to main content

Module color

Module color 

Source
Expand description

Colors and themes.

Structs§

Theme
Renderer colors. Scene color 0 means Theme::foreground.

Functions§

pack
Pack straight-alpha components.
parse_hex
Parse #rgb, #rrggbb or #rrggbbaa.
premul_bytes
Convert to the vertex format: premultiplied RGBA8, little-endian [r, g, b, a].
unpack
Unpack to straight-alpha components in 0..=1.
with_alpha
Multiply the alpha channel.

Type Aliases§

Rgba
Packed 0xRRGGBBAA color (the scene contract’s Rgba).