Drawing with python.

Fernando Perez fperez528 at yahoo.com
Mon Jun 28 13:22:16 EDT 2004


aleator wrote:

> 
> Hello.
> 
> What is the recommendable means of producing
> bitmaps with python. Basic primitives I need
> are polygons, antialiased lines and ellipses.
> 
> I have tried, so far, GD-module (Very slow) and
> Pygame(Antialiased lines are ugly, pixelated).
> 
> I do not necessarily need to produce bitmaps, any image
> that is good for wxpython application and WWW is good
> enough.

Depending on your exact needs, PyX or matplotlib may fit the bill.  matplotlib
uses AGG, so it renders beautifully antialiased lines, but it's more geared
towards plotting.  PyX has more raw primitives for drawing exposed, but it's
main output target is PostScript (which you can of course easily convert later
at any desired resolution).

Cheers,

f



More information about the Python-list mailing list