lib.ogl classes big problem. Help me!

Robin Dunn <robin@alldunn.com> writes:

>
> Because of the way that OGL objects keep references to each other, and
> the way that Python reference counting works, you end up with a lot of
> reference cycles that don't get cleaned up very well. Since it was
> ported from C++ code where you don't have to worry about forcing object
> destruction when circular references are present this is a natural side
> effect of the port. It would be nice if somebody wanted to go over OGL
> and modify most of those references to be weak refs instead, but in the
> mean time you need to do some cleanup yourself.
>
I remember fixing a huge resource leak when I did the port, and that single
one took me hours to track down. I also remember thinking that weakrefs wasn't
a solution, but right now I can't remember why I would have thought that, so
Robin is probably right.

If I have time this weekend, I might look into this a bit.

--
  Pierre Hjälm

---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help@lists.wxwidgets.org

The suggestion of Robin Dunn is right on the simple example that I produced last week, but
in general case (I use many ogl classes: BitmapShape, RectangleShape, CompositShape etc.)
the problem is not resolved (expecially if I have a CompositShape of CompositShape).
Someone can help me?

Regards,
Stefano C.