When I was writing FLTK port I need masking too. You can see my solve here http://git.directfb.org/?p=ports/FLTK_1.x-DirectFB.git;a=blob;f=src/_image.cxx;h=739c40affb701c202f53994b95bf2d6b8ba655ca;hb=15b6b3b68d6bcd127af8760cbba733461f0541a5 fl_copy_offscreen(),line 491 The "clip_mask" variable is a surface with A8 pixel format.
2008/3/26, Mark Jackson <[EMAIL PROTECTED]>: > > I have one image on a RGB24 (DSPF_RGB24) surface and a separate alpha > mask in an 8-bit alpha surface (DSPF_A8). I am trying to blit the image > onto a second RGB24 surface using the 8 bit alpha as the mask for the > blit, in other words I want the source pixels to replace destination > pixels where alpha = 0xff, otherwise the destination pixels should stay > the same. Note that the alpha is stored separately in an 8 bit surface > for historical / code porting reasons, but the only possible value for > each alpha pixel in this case will be either 0 or 0xff. > > What is the best / most efficient way to do this with the DirectFB api, > given the constraints above? > > - Mark > > _______________________________________________ > directfb-users mailing list > directfb-users@directfb.org > http://mail.directfb.org/cgi-bin/mailman/listinfo/directfb-users > -- Best Regards Nikita Egorov [EMAIL PROTECTED] [EMAIL PROTECTED]
_______________________________________________ directfb-users mailing list directfb-users@directfb.org http://mail.directfb.org/cgi-bin/mailman/listinfo/directfb-users