Re: CIImage drawAtPoint: ...... retains image??
Re: CIImage drawAtPoint: ...... retains image??
- Subject: Re: CIImage drawAtPoint: ...... retains image??
- From: Andreas Monitzer <email@hidden>
- Date: Sat, 15 Dec 2007 12:44:55 +0100
On Dec 15, 2007, at 08:36, Nik Youdale wrote:
I see - thanks for the explanation on retain count - it makes sense.
I'm using 'Instruments' (previously known as XRay - why did they
change the name?....) with the object alloc tool, and it appears
that most memory is being used by QuartzCore in a massive tree of
calls going something like "fe_tree_create_texture > fe_texture_new
> texture_retain > blah blah blah".
Disabling the drawAtPoint: call clears up the memory leaks.
So it appears that its a whole bunch of functions within QuartzCore
and CoreGraphics causing the issue - of course appearances can be
deceiving.
I'm seeing the same issue in my program. As soon as I try to render
the CIImage somehow (to my view or offscreen), the whole image leaks.
Since I'm drawing fullscreen images regularly, my application leaks
60MB of RAM per cycle (verified using Instruments). The memory is
never freed in any way, it just builds up.
I haven't found a solution yet, even though I spent a whole day trying
different ways to get the pixels out of the CIImage (all of them
leaking). I'm thinking about scrapping CIImage altogether and re-
implementing all CoreImage filters I'm using using direct OpenGL calls
and some shaders. That's much more work, but at least I can fix those
leaks that way.
andy
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden