forced palette for RGBA images

thomas bonfort thomas.bonfort at GMAIL.COM
Thu Dec 6 12:47:09 EST 2007


Not that I know of appart from some questionnable choices in libpng of
aborting compilation if setjmp.h was already included beforehand (even
if it's properly #ifdef'd)

are you thinking of something in particular?

tb

On Dec 6, 2007 6:07 PM, Steve Lime <Steve.Lime at dnr.state.mn.us> wrote:
> Sounds cool. Any configuration issues related to libpng?
>
> Steve
>
> >>> On 12/6/2007 at 10:07 AM, in message
> <d2b988930712060807n281f8850t386bd85182bd1a22 at mail.gmail.com>, thomas bonfort
>
> <thomas.bonfort at GMAIL.COM> wrote:
> > hello list,
> >
> > I've added the possiblity to force a color palette for RGBA images. As
> > gd does not support this kind of images, I had to resort to directly
> > use libpng functions for the actual saving of the file.
> >
> > The steps needed to actually use this would be:
> > - create a 24 bit rgba image representative of a typical image that
> > would be produced
> > - use an external program to create an rgba paletted version of the
> > image (pngquant, pngnq, photoshop...)
> > - extract the palette from the created image and save the values in
> > the form r,g,b,a in a text file (one per line)
> > - use palette_force and palette formatoptions in the outputformat block.
> >
> > This is rather complicated, but usefull on production setups to
> > minimize image size when using clients that overlay layers (eg
> > openlayers).
> >
> > There are still a few quirks I'd have to work on before the code is
> > robust enough for inclusion in the trunk, so I'd like to know if this
> > is a feature we'd definitely like to have before putting too much
> > effort into that.
> >
> > cheers,
> > thomas
>
>



More information about the mapserver-dev mailing list