[cairo] A8 images as source?
Carl Worth
cworth at cworth.org
Wed Sep 24 13:10:40 PDT 2008
On Sun, 2008-09-14 at 22:56 -0700, Bill Spitzak wrote:
> Doing cairo_set_source_surface(cr, anA8image) and drawing reveals that
> it treats the A8 cairo_image_t as having r=g=b=0, and only the alpha
> channel non-zero.
...
> This would change the results whenever an A8 image is used as the source
> (rather than for cairo_mask_surface()). For instance a normal over would
> draw white instead of black (but you could use DEST_OUT or some other
> operators to get black again). So I am not sure how many programs this
> would break. An alternative is to add yet another image format.
I would hope that it wouldn't break too many applications, (since using
an A8 surface as a source right now is so useless that hopefully nobody
is doing it). There's been a similar request to make using an RGB24
surface as a mask do something useful rather than just using alpha=0.
I'd actually be willing to consider both of those changes. We'd just
need to see some code.
-Carl
More information about the cairo
mailing list