SourceForge logo
SourceForge logo
Menu

Re: [matplotlib-devel] Unnecessary rerendering in wx/wxagg backends

From: Erik T. <eri...@gm...> - 2008年03月31日 17:34:28
I tested this on 0.91.2 on Ubuntu Gutsy, and wx 2.8.7.1, and found
that when I bring up a new window, I see a black canvas and it doesn't
draw any of the matplotlib objects until I do something like resizing
that must explicitly call a draw at some point. This may be why it's
in there... perhaps some sort of checking to see if any draw has been
performed yet?
On Mon, Mar 31, 2008 at 7:58 AM, Gregor Thalhammer
<gre...@gm...> wrote:
> Dear developers,
>
> I discovered that in backend_wx.py in _onPaint(), the callback function
> for repainting a matplotlib figure, every time a repaint is done also
> the bitmap is rerendered:
>
> backend_wx.py/_onPaint():
> ...
> # Render to the bitmap
> self.draw(repaint=False)
> ...
>
> This also affects the behaviour of the wxagg backend. Rerendering and
> therefore also repainting gets quite slow if, e.g., images are included
> in the figure. I can see this by simply dragging another window across
> the matplotlibfigure. Commenting out the rerendering I get a much
> smoother behaviour. I could not observe problems except that sometimes
> some parts of the figure are not properly repainted if the matplotlib
> figure is in the background (I only tested the wxagg backend). Therefore
> it seems that this rerendering every time a repaint is performed is not
> really necessary and should be avoided.
>
> I tested this on matplotlib 0.91.2 on WinXP, Python 2.5, wx 2.8.7. I
> checked that in the current svn version the _onPaint() function is
> unchanged.
>
> Gregor
>
> -------------------------------------------------------------------------
> Check out the new SourceForge.net Marketplace.
> It's the best place to buy or sell services for
> just about anything Open Source.
> http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
> _______________________________________________
> Matplotlib-devel mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
>
-- 
Erik Tollerud
Graduate Student
Center For Cosmology
Department of Physics and Astronomy
4155B Frederick Reines Hall
University of California, Irvine
Office Phone: (949)824-2996
Cell: (651)307-9409
eto...@uc...

View entire thread

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.
Thanks for helping keep SourceForge clean.
X





Briefly describe the problem (required):
Upload screenshot of ad (required):
Select a file, or drag & drop file here.
Screenshot instructions:

Click URL instructions:
Right-click on the ad, choose "Copy Link", then paste here →
(This may not be possible with some types of ads)

More information about our ad policies

Ad destination/click URL:

AltStyle によって変換されたページ (->オリジナル) /