[Mapserver-users] Mapserver 4.0 as WMS server issuing transparent PNG

Daniel Morissette morissette at dmsolutions.ca
Fri Sep 26 08:24:33 PDT 2003


Lars V. Nielsen wrote:
>  
> Today I've (finally) migrated to Mapserver 4.0, and needed to migrate 
> several locally cascaded WMS services too. All but one of these are used 
> to generate backdrops, i.e. not transparent, but a single service is 
> used to publish thematic layers to be shown on top of other layers. So 
> this service needs to issue transparent map images, and therefore I'm 
> using PNG.
>  
> However, only the surrounding area is transparent, not the interior of 
> the polygons features, even though these are set to 50% transparency. 
> What am I doing wrong ?
>  

The transparency setting applies only between local layers inside 
MapServer.  Setting 50% transparency in a layer served via WMS doesn't 
carry the transparency to the remote WMS clients.

What you could do is produce a dithering effect to emulate transparency. 
  i.e. fill your polygons with a tiny hatch pattern or a symbol that 
covers only 50% of the pixels, the other half of the pixels will remain 
of the background color and will end up being transparent in the WMS 
GetMap output.

Daniel
-- 
------------------------------------------------------------
  Daniel Morissette               morissette at dmsolutions.ca
  DM Solutions Group              http://www.dmsolutions.ca/
------------------------------------------------------------




More information about the MapServer-users mailing list