[cairo] RGB channels are set to zero if alpha is 0.

Bill Spitzak spitzak at gmail.com
Mon Aug 28 19:08:56 UTC 2017

On Mon, Aug 28, 2017 at 10:42 AM, Behdad Esfahbod <behdad at cs.toronto.edu> wrote:
> Really? Majority of PNG files are premultiplied and they render visually
> alright?!  Hard to believe...

Yes because programs that think they are unpremultiplied
double-premultiply the alpha. This results in dark fringes around the
edges but the error is hard to see. My tests were based on png files
found on the web and used in the film industry about 8 years ago,
where it was virtually impossible to find a non-premultiplied one
(ignoring ones with the alpha all 1 and 0 where you cannot tell). It
may be useful to see if the proportion has changed more recently.

More information about the cairo mailing list