Hazen,

Many thanks for this. It's a useful feature to have and I'm glad someone
has finally got round to starting to code it in. I've added support for 
alpha values to the gd driver too so hopefully more people can test it out.

Note that libgd uses integer alpha values in the range 0-127 with 0
being opaque. This is quite different to the convention in cairo, and
also now in plplot. I'm happy to stick with the 0.0-1.0 range with 1.0
as opaque though since this seems more natural. I'm fairly sure this is 
what I have seen elsewhere too. 

Regards

Andrew

On Sun, Jan 06, 2008 at 03:33:55PM -0500, Hazen Babcock wrote:
> 
> Hello,
> 
> I've added alpha value support to plplot core as discussed many  
> months ago. I did this by (1) adding an additional member to the  
> PLColor structure to store the alpha value and (2) adding a bunch of  
> new functions to the API so that you can fiddle with the alpha value.  
> I've also added a  new example (x30) to demonstrate how to use some  
> of the functions and what the effects of alpha values are in general.  
> At present only the cairo device driver is alpha aware so you should  
> not see any differences when using any of the other drivers.
> 
> The new functions are:
> plscolbga(PLINT r, PLINT g, PLINT b, PLFLT a)
> plgcolbga(PLINT *r, PLINT *g, PLINT *b, PLFLT *a)
> plscol0a(PLINT icol0, PLINT r, PLINT g, PLINT b, PLFLT a)
> plgcol0a(PLINT icol0, PLINT *r, PLINT *g, PLINT *b, PLFLT *a)
> plscmap0a(PLINT *r, PLINT *g, PLINT *b, PLFLT *a, PLINT ncol0)
> 
> Note that at present you can only change / interrogate the alpha  
> values for color table 0.
> 
> Thoughts?
> 
> -Hazen
> 
> 
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio 2005.
> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
> _______________________________________________
> Plplot-devel mailing list
> Plplot-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/plplot-devel
> 

-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
_______________________________________________
Plplot-devel mailing list
Plplot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/plplot-devel

Reply via email to