AGG and WMS

Brent Fraser bfraser at GEOANALYTIC.COM
Thu Aug 23 16:44:08 EDT 2007


Looks like the grey background is a problem with Internet
Explorer 6 and png files.

Brent Fraser
GeoAnalytic Inc.
Calgary, Alberta
----- Original Message ----- 
From: "Brent Fraser" <bfraser at GEOANALYTIC.COM>
To: <MAPSERVER-USERS at LISTS.UMN.EDU>
Sent: Thursday, August 23, 2007 2:28 PM
Subject: Re: [UMN_MAPSERVER-USERS] AGG and WMS


> Assefa,
>
> Stranglely, adding
>    MIMETYPE "image/png"
> or
>    MIMETYPE "image/png; mode=24bit"
> gives a 24 bit file, anti-aliased, but with grey instead
of
> a white background.
>
> Brent Fraser
> GeoAnalytic Inc.
> Calgary, Alberta
> ----- Original Message ----- 
> From: "Yewondwossen Assefa" <assefa at dmsolutions.ca>
> To: "Brent Fraser" <bfraser at GEOANALYTIC.COM>
> Cc: <MAPSERVER-USERS at LISTS.UMN.EDU>
> Sent: Thursday, August 23, 2007 2:18 PM
> Subject: Re: [UMN_MAPSERVER-USERS] AGG and WMS
>
>
> > Brent,
> >
> >   I think what happens is the following : when mapserver
> gets your wms
> > request with FORMAT=png, it selects the the GD PNG 8 bit
> driver. I am
> > not sure right now wms/outputformat should be handled so
> that this king
> > of situation does not happen.
> >   A quick work around from what I can see would be
> >
> >    - define an agg output format is your map file :
> >       OUTPUTFORMAT
> >      NAME "agg/png24"
> >      MIMETYPE "image/png; mode=24bit"
> >      DRIVER "AGG/PNG"
> >      EXTENSION "png"
> >    END
> >
> >   - set you imagetyppe in the map file to be IMAGETYPE
> agg/png24
> >
> >   - when doing a wms request use FORMAT=image/png;
> mode=24bit
> >
> >   This should ensure that your agg output format is
used.
> >
> >   Best Regards,
> >
> >
> > Brent Fraser wrote:
> > > Christopher,
> > >
> > >   Sorry for the terse question, here are some more
> > > details...
> > >
> > > I'm using the AGG/PNG output driver (see RFC-32) in
> > > Mapserver 5.0 beta 4 to render shapefile vectors (no
> raster
> > > input) to a PNG graphic file.  When I use Mapserver's
> CGI
> > > interface to request a graphic map, the lines appear
> > > anti-aliased (smooth, no jaggies) Great!  But when I
use
> > > Mapserver's WMS interface, I get the same old
rendering
> > > Mapserver always gave (lines with jaggies).
> > >
> > >   Note there was an email
> > >
>
(http://lists.umn.edu/cgi-bin/wa?A2=ind0703&L=mapserver-dev&
> > > T=0&O=D&X=639F0B08FDD720FAC9&P=6714) saying "WSM right
> now
> > > only advertise gd and gdal based drivers. See bug
455".
> > >
> > >
> > >   After some review of the images, it looks like my
> "DRIVER
> > > AGG/PNG" produces a 24 bit png file via CGI, but an 8
> bit
> > > png file via WMS.  When I try to do AGG/PNG24, I get
> > > "General error message. OUTPUTFORMAT clause references
> > > driver AGG/PNG24, but this driver isn't configured."
> from
> > > Mapserver.  I'll have to do some more digging...
> > >
> > > Brent Fraser
> > > GeoAnalytic Inc.
> > > Calgary, Alberta
> > >
> > > ----- Original Message ----- 
> > > From: "Christopher Schmidt" <crschmidt at METACARTA.COM>
> > > To: <MAPSERVER-USERS at LISTS.UMN.EDU>
> > > Sent: Thursday, August 23, 2007 1:03 PM
> > > Subject: Re: [UMN_MAPSERVER-USERS] AGG and WMS
> > >
> > >
> > >> On Thu, Aug 23, 2007 at 12:32:41PM -0600, Brent
Fraser
> > > wrote:
> > >>> Is AGG supposed to do anti-aliased output when
> Mapserver
> > > is
> > >>> used as a WMS server?
> > >> I'm not sure what 'antialiased' output means -- 
perhaps
> > > you mean 'alpha
> > >> transparency', perhaps you mean antialiasing within
the
> > > images, perhaps
> > >> you mean something else. Can you clarify?
> > >>
> > >> The answer to the first is, I believe,  "no". WMS
spec
> > > only allows for
> > >> 'transparency or no transparency', and MapServer does
> not
> > > implement
> > >> alpha transparency output in the WMS images.
> > >>
> > >> The answer to the second is "Sure" -- the images for
> > >> http://boston.freemap.in/ are fetched from WMS (by
> > > TileCache).
> > >> Regards,
> > >> -- 
> > >> Christopher Schmidt
> > >> MetaCarta
> > >
> >
> >
> > -- 
>
> ----------------------------------------------------------
> ------
> > Assefa Yewondwossen
> > Software Analyst
> >
> > Email: assefa at dmsolutions.ca
> > http://www.dmsolutions.ca/
> >
> > Phone: (613) 565-5056 (ext 14)
> > Fax:   (613) 565-0925
>
> ----------------------------------------------------------
> ------
> >



More information about the mapserver-users mailing list