Skip to content

cf_image_premultiply

Category: image
GitHub: cute_image.h


Premultiplies the alpha component of each pixel with the RGB color components.

void cf_image_premultiply(CF_Image* img);
Parameters Description
img The image to premultiply.

Remarks

Premultiplying images is a common way to deal with colors, especially when blending. Here is a good resource for learning about premultiplied alpha.

CF_Image