On Sat, Feb 6, 2010 at 2:24 PM, Oleg Kobchenko <[email protected]> wrote: >> From: June Kim <[email protected]> > >> >> Is there anyway to set the alpha value(transparency) with gl2? >
First of all, thanks for answering my question, Oleg. > I don't think transparency is supported by gl2 directly, > but it should be easy to achieve though bitblt (glqpixels, glpixels). Could you give me a simple running example of using it, please? > > See "Image Operations" in J Wiki > > http://www.jsoftware.com/jwiki/OlegKobchenko/Image%20Operations > > Basically, for a color component, transparency is weighted sum, > the complement of which to 1 is opacity. > > C = F*O + B*(1 - O) > > C is the new color component value > B is the background value (0..1) > F is the foreground value (0..1) > O is the foreground opacity (0..1) > > > ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
