Complete.Org: Mailing Lists: Archives: freeciv-dev: March 1999:
Re: [Freeciv-Dev] xpm, gif, png & map view!
Home

Re: [Freeciv-Dev] xpm, gif, png & map view!

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Markus Linnala <maage@xxxxxxxxx>
Cc: freeciv-dev@xxxxxxxxxxx
Subject: Re: [Freeciv-Dev] xpm, gif, png & map view!
From: Vasco Alexandre Da Silva Costa <vasc@xxxxxxxxxxxxxxxxxxxxx>
Date: Tue, 9 Mar 1999 12:24:38 +0000 (WET)

On 8 Mar 1999, Markus Linnala wrote:

> Matt Busigin <jediknight@xxxxxxxxx> writes:
> 
> Here's patch to add imlib support and support for libz.
> 
> Support for imlib means it can load arbitrary image format and
> render it suitable for your display without too much problems
> automatically.

Hello there.  As someone mentioned before not everyone has Imlib and i've
seen several sysadm's refuse installation because it's not secure enough
(when Imlib fails to recognize the format it calls NetPBM).

I personally have been hating Imlib more and more as i've used it.  My
reasons are:

* to compile a program using Imlib you need libtiff, libgif, libjpeg, 
  libpng, libz.  If that isn't a bit over the top i don't know what is.
* why doesn't GdkImlib actually use Gdk?
* why does Imlib create a lib for EVERY single file format it handles,
  besides the main one?
* why does Imlib end up doing stuff that is done in GdkRgb over and over
  again?

It kind of makes you wonder why the GIMP doesn't use Imlib doesn't it?  It
looks like the GIMP could use it but they go their own way instead, it's
not hard to figure out why.

=== What i would like to see in Imlib is:

* it being programed using Gdk & GdkRgb: no direct X calls please.
* make Imlib use GIMP plugins to load images.  This way the possibilities
  are endless.
* move Imlib into Gdk.  I see no need for yet another lib.

> The Rasterman <raster@xxxxxxxxxx> told me XPM fileformat
> supports only 256 colours and more than that means programs
> might not support or support is inefficient. Anyone have full
> XPM documentation to verify this.

Huh?  Then how come i've seen and used 24-bit XPM's?  XV, libXpm, GIMP 
and everything else seem to support them so i don't really see your
problem.

XPM parsing is slow and the files are big however.  That's why i made a
version which used TGA's which have RLE compression and are in raw binary 
format. However the compression methods of GIF/PNG are much more advanced
than RLE.  The advantage of TGA is that it's a very simple file format.

I could use libpng+libz though.  I just need a more efficient way to do 
color quantization & dithering than the one i used before (for the Xaw
version since in the GTK+ one i can just use GdkRgb).

---
Vasco Alexandre da Silva Costa, student @ Instituto Superior Tecnico,
Technical University of Lisbon - Software & Computer Engineering



[Prev in Thread] Current Thread [Next in Thread]