Re: Create an image Browser
Re: Create an image Browser
- Subject: Re: Create an image Browser
- From: "John C. Fox" <email@hidden>
- Date: Wed, 11 Feb 2004 16:59:53 -0800
Hi:
Yes, Epeg is great, and I've already been using it. It always helps to
cut down the amount of image data that is being displayed. Right now, I
pre-scale the thumbnails to fit within 100 X 100 pixels then cache the
results in a dictionary so that as the user goes back and forth, the
thumbnails don't have to be re-rendered.
I will soon be experimenting with displaying even less data while
scrolling, then filling in the rest when the user releases the mouse.
With iPhoto, only thumbnails are being displayed, so I assume that
there is a single view and each of the individual thumbnails are
composited within a single view.
In my app, I need to display thumbnails, metadata, and buttons, so I
have no choice to create views. I suppose that's the issue; there's no
way that I can think of to have all the event handling you need in a
view when you need it, without paying the price in overhead when you
don't need it (i.e. when you're scrolling).
What I have will do (it's as fast as the iPhoto library display within
iMovie) but I want speed speed speed!!
At any rate, I'm happy to share my ideas and progress with anyone on
the list that's interested. Just drop me a line.
Take care,
John
On Feb 11, 2004, at 3:15 PM, M. Uli Kusterer wrote:
At 9:22 Uhr -0800 10.02.2004, email@hidden wrote:
iPhoto uses its own custom view, and is obviously very fast, largely
it seems, due to some clever tricks with only displaying part of the
thumbnail data while scrolling, then waiting for the user to let go
of the mouse before the rest of the data is fetched and drawn. I
invite members of the iPhoto team to share their secrets with the
list. ;-) ;-)
Have you checked out libEpeg yet? It's a JPEG decompression library
for which someone on this list recently announced an ObjC wrapper.
Basically, it decodes only the first couple of coefficients in the
JPEG, which means it can generate small previews quite easily without
having to load and scale down the image.
For other image types, I guess the only approach would be to generate
previews using QuickTime (QuickTime will attack previews to a file's
resource fork) and then displaying the preview during scrolling, and
the actual scaled image once scrolling is finished.
--
Cheers,
M. Uli Kusterer
------------------------------------------------------------
"The Witnesses of TeachText are everywhere..."
http://www.zathras.de
----
John C. Fox
CTO
WebWare Product Group/INSCI
www.webwarecorp.com
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.