Hardware accelerated graphics: Double buffered window?

Mr. Anonymous aeronautics2412 at hotmail.com
Wed Feb 14 19:18:47 PST 2007


Hello Everyone,

I have recently adopted Python for AI research at my University.  I stumbled 
upon wxPython and was quite impressed with its elegance and ease of use for 
GUI creation.  Compliments aside, I’m trying to figure out what classes to 
use for creating a double buffered window to draw to.  I would like to 
create some visual 2D environments for some of my software agents (2D games 
essentially).  I suspect wxPython will be fast enough as they will not be 
true games, but will require flicker free drawing and animation abilities 
plus some GUI widgets from wxPython (Hence why PyGame is not sufficient).  
I’m just trying to figure out what classes will yield the best results.

Currently I found the package:
     wx.lib.colourchooser.canvas
containing the Canvas class.

*Question* - Is this the class I should use for my drawing surface and then 
use the wx.Bitmap class to store my images to be drawn to the Canvas’s 
off-screen buffer?  Or should I draw directly to a BitmapBuffer using my 
images and then blit the BitmapBuffer to the Canvas?

Thank you for your time, any help is greatly appreciated.

-Paul

_________________________________________________________________
>From predictions to trailers, check out the MSN Entertainment Guide to the 
Academy Awards® 
http://movies.msn.com/movies/oscars2007/?icid=ncoscartagline1





More information about the wxpython-users mailing list