Some optimization opportunities

Luciano Montanaro mikelima at cirulla.net
Sat Jun 19 17:27:07 CEST 2004


On Saturday 19 June 2004 15:39, Maks Orlovich wrote:
> > I think it should not... If I recall correctly, Qt can handle 32bpp and
> > 8bpp images, and 8bpp images are expanded on the fly when drawn on the
> > screen. The drawing may take a bit longer to complete (but maybe not,
> > since there are fewer bytes to read), but the memory saving, as you say,
> > may be worth the penalty.
>
> Uhm, we cache icons in memory as -pixmaps-. 

I assumed - wrongly - that Qt could use XPixmaps of any depth the XServer
can handle. I have seen this is not the case.

> Not images. So they're always 
> in native format for the X server as soon as loaded. Also, what makes you
> think that:
> 1. KIconEffect/KImageEffect application works with paletted items?

Well, at least some of the effects could be done on paletted images.
Contrast/gamma/desaturation/colorization effects could be achieved by 
changing the palette instead of the graphics data. 

> 2. There is a noticeable memory use for icons

I guess not... xrestop says konqueror in file management mode consumes
228K of pixmap memory.

> 3. You can do the conversion with acceptable quality.

I suspect conversion to a 256 color palette mode would not degrade quality 
significantly, at least at smaller icon sizes. 

However, since this will not gain us anything, except perhaps disk space,
there is little reason to do this.

Luciano


More information about the Kde-optimize mailing list