On Feb 22, 2007, at 1:11 PM, Christopher Barker wrote: > >> More importantly, I written another set of the agg-to-wx.Bitmap >> conversion routines that uses the new BitmapFromBufferRGBA() >> function in wxPython 2.8. > > Are these in Python or c++?
Since BitmapFromBuffer() and its aforementioned cousin are covered in the wxWidgets documentation for wxBitmap, I believe they're mostly in C++. >> The blit() >> routine also got a bit faster after I realized it was more efficient >> to just convert the whole buffer and blit part of it instead of >> clipping during conversion. > > really? interesting -- it shows you never know! Yep. Benchmarking is your friend! >> I have tested these changes with wxPython 2.8.1.1 under OSX 10.4.8. >> My goal is that none of the changes break compatibility with wxPython >> 2.4 or 2.6. > > um, how is that possible if you're using the new 2.8 functions? There are two conditional checks based on wx.__version__. One is in setup.py to not build the C++ accelerator for wxPython 2.8. The other is in backend_wxagg.py and figures out which of the three agg/ wx.Bitmap conversion implementations to use -- the pure Python routines, the C++ accelerator, or the wxPython 2.8 edition of the pure Python routines. >> I'd really appreciate it if someone could test and >> benchmark those versions using `examples/animation_blit_wx.py'. > > I'll see what I can do. > > By the way, did you see the weird toolbar behavior with 2.8 on OS-X? It didn't jump out at me, but I wasn't paying much attention. I'll try to reproduce it tomorrow. Ken ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys-and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Matplotlib-devel mailing list Matplotlib-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-devel