[plug] Interactive generation of polygons from segments

Cameron Patrick cameron at patrick.wattle.id.au
Sun Jul 17 18:44:59 WST 2005


Jim Leven wrote:

> Thanks Craig - I'm looking at pygtk. I would be 
> grateful for recommendations on whether OpenGL or 
> pygtk is the better path to tread.  I have only 
> ventured a few steps down the pygtk route.

OpenGL is certainly the way to go if you want anything in 3D, or if
you think you might want to extend it to 3D later.  It can still be
used for 2D stuff, though, but I think in that case pygtk might be a
bit easier to use.  PyGTK provides all the other bits you'd need to
build an interface, as well as some simple 2D drawing functions.  If
you went the GL route you'd probably want to embed some the GL display
in a user interface toolkit like PyGTK or PyQT anyway.

I'm also going to mention matplotlib http://matplotlib.sourceforge.net/ 
which is a very handy plotting library for Python.  I don't think it's
directly useful for what you're after, but then again things like
drawing a scatter graph might have quite a bit in common with drawing
nice polygons, and it allows you at least a little bit of interactivity
in terms to doing stuff to your plots when they're clicked on and so on.

Cameron.




More information about the plug mailing list