canvaskit-wasm 0.39 build 2026-04-29

AlphaType

How the alpha channel of a pixel buffer relates to its color channels. Carried on ImageInfo and consumed by MakeImage, readPixels, etc.

All values

ValueStorage
PremulRGB is already multiplied by alpha. (0.5, 0, 0, 0.5) means 50% red at 50% alpha. Skia's preferred internal format.
UnpremulRGB independent of alpha. (1, 0, 0, 0.5) means full red at 50% alpha. What CSS / SVG / browser color-pickers use.
OpaqueAlpha is implicitly 1. Saves a channel; the alpha bytes (if present) are ignored.

See also