Expand description
Optimized alpha blending routines based on libwebp
Functionsยง
- blend_
channel_ ๐nonpremult - Blend a single channel of
src
overdst
, given their alpha channel values.src
anddst
are assumed to be NOT pre-multiplied by alpha. - blend_
pixel_ ๐nonpremult - Blend
src
overdst
assuming they are NOT pre-multiplied by alpha. - channel_
shift ๐ - div_
by_ ๐255 - Divides by 255, rounding to nearest (as opposed to down, like regular integer division does). TODO: cannot output 256, so the output is effecitively u8. Plumb that through the code.
- do_
alpha_ ๐blending