Re: CATiledLayer tile invalidation
Re: CATiledLayer tile invalidation
- Subject: Re: CATiledLayer tile invalidation
- From: John Harper <email@hidden>
- Date: Mon, 24 Mar 2008 09:01:25 -0700
No, there's no way to do that right now, CATiledLayer doesn't even
know when tiles are evicted from the cache. Probably the best thing to
do is to give your cache a maximum size and remove items after they've
been idle for some timeā¦
John
On Mar 24, 2008, at 8:39 AM, Dmitry Pugachev wrote:
I'm writing an application that dynamically renders
contents into a large scrollable view, and I'm using
a CATiledLayer object as a content layer. It handles
tiled drawing pretty well, but I also want to be able
to synchronize it with my internal cache, which contains
temporary data for each tile being rendered.
While I can add content to this internal cache as I
render individual tiles, I can't seem to be able to
invalidate off-sceen portions of the cache when
the corresponding portions of the internal CATiledLayer
image buffer get invalidated. For example, if I scroll
down continuously, each new tile rendered would
add data to my internal cache, while the old tiles
will never get invalidated. On the other hand, I want
to be able to keep the cache size under control by
removing old content, just like CATiledLayer does
for its internal image data.
Is there a way to register a callback that will be
invoked by CATiledLayer when it internally
invalidates an outdated portion of its content?
Thanks in advance,
Dmitry
_______________________________________________
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
_______________________________________________
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