|
From: Bruce S. <bas...@nc...> - 2010-11-01 17:33:30
|
Consider the following trivial program:
from visual import *
s = sphere()
s.visible = False
The creation of the sphere causes a window to be created, which
remains there when the sphere is made invisible. There is nothing to
be rendered, but at the very least the rendering thread has to check
whether there is anything to render, and whether there are any mouse
or keyboard events. And yet I find that there is a memory leak on
Windows of about 1 MB/minute and on Mac of about 3 MB/minute.
People ran into trouble with what seemed to be problems with curve,
but clearly the problem is more general.
I also tried the following code on Windows, creating 10 windows:
from visual import *
for n in range(10):
display()
s = sphere()
s.visible = False
The leak rate was again about 1 MB/minute on Windows, so the number of
windows doesn't matter. Evidently the problem is localized to
starting/ending the render thread. I don't know yet what the problem
is.
Bruce Sherwood
|