[cairo] Fix for CAIRO_FORMAT_RGB24 pngs

Carl Worth cworth at redhat.com
Tue May 17 16:18:07 PDT 2005


On Tue, 17 May 2005 18:34:09 -0400, Owen Taylor wrote:
> It just breaks when we don't go through unpremultiply data when
> writing RGB24 pngs. Definitely needs some cleanup so that 
> we don't do a confusing MSB => LSB => MSB dance.

All my fault.

I wrote some code on my little-endian processor and it worked.

Later I tried it on a big-endian processor, and unsurprisingly, it did
not.

I needed a conditional byte-swap and the fiddling we were already
doing in (un)premultiply looked like a nice place to drop it.

Cleanups gladly accepted.

-Carl

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/cairo/attachments/20050517/04c694c4/attachment.pgp


More information about the cairo mailing list