Re: [Nautilus-list] Nautilus Performance Analysis



On 14 Aug 2001 10:30:51 -0700, Darin Adler wrote:

> > it seems the jpeg reader is asking the OS to read tiny little bits at a 
> > time
> 
> We are reading it with gdk-pixbuf. I imagine this is a bug in the 

It looks like Nautilus uses gdk_pixbuf_new_from_file() a lot. You can
control the chunk size you're loading if you approach it another way.

Read big chunks from another thread (gnome-vfs in the current case) --
64k or more at a time -- and then feed the chunk to
gdk_pixbuf_loader_write(). You can have
gdk_pixbuf_render_to_drawable[_alpha] get called via signals if you want
to update a drawable as the image is loaded.

Currently, gdk_pixbuf_loader_write() is used only in
nautilus-image-view.c

Of course, using gdk_pixbuf_loader_write() also means that you can
implement your own cache a little more cleanly, I would think.

-Michael





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]