Thomas Robitaille wrote:
> Hello,
> 
> The following code should produce identical plots, but in the second  
> case the alpha value is ignored:
> 
> ---
> 
> import matplotlib
> matplotlib.use('Agg')
> import matplotlib.pyplot as mpl
> from matplotlib.patches import Ellipse
> from matplotlib.collections import PatchCollection
> 
> fig = mpl.figure()
> ax = fig.add_subplot(111)
> ax.add_patch(Ellipse((0.5,0.5),0.7,0.3,angle=30,alpha=0.3))
> fig.savefig('test1.png')
> 
> fig = mpl.figure()
> ax = fig.add_subplot(111)
> ax.add_collection(PatchCollection([Ellipse((0.5,0.5), 
> 0.7,0.3,angle=30,alpha=0.3)],match_original=True))
> fig.savefig('test2.png
> 
> ---
> 
> Is this a bug? I'm using the latest svn version of matplotlib.

Yes.  Alpha-handling in general is a confusing mess in mpl.  Ideally, it 
needs an overhaul rather than an isolated bug-fix or two.  This might 
best be done in the context of a color-handling overhaul, which we have 
discussed a little bit.

Eric

> 
> Thanks,
> 
> Thomas
> 
> 
> 
> ------------------------------------------------------------------------------
> The NEW KODAK i700 Series Scanners deliver under ANY circumstances! Your
> production scanning environment may not be a perfect world - but thanks to
> Kodak, there's a perfect scanner to get the job done! With the NEW KODAK i700
> Series Scanner you'll get full speed at 300 dpi even with all image 
> processing features enabled. http://p.sf.net/sfu/kodak-com
> _______________________________________________
> Matplotlib-users mailing list
> Matplotlib-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users


------------------------------------------------------------------------------
The NEW KODAK i700 Series Scanners deliver under ANY circumstances! Your
production scanning environment may not be a perfect world - but thanks to
Kodak, there's a perfect scanner to get the job done! With the NEW KODAK i700
Series Scanner you'll get full speed at 300 dpi even with all image 
processing features enabled. http://p.sf.net/sfu/kodak-com
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to