[mapserver-users] Transparent layers

Tomas Krecmer tokr at tmapy.cz
Sun May 26 23:02:50 PDT 2002


There is no other requirements than MapServer 3.6+ itself. I use this 
parameter in the CGI version only defining it in the map file. Can you, 
Vinko, try this feature in the your CGI version too. Let me know if it 
fails or not. I would than check the PHP MapScript code.

Tomas

-- 
Tomas Krecmer, tokr at tmapy.cz
T-Mapy spol. s r. o., Nezvalova 850, 500 03 Hradec Kralove,
Czech Republic, phone: + 420 49 5513335 , fax + 420 49 5513371



randy james wrote:
> I used transparency without modifying the source code.
> 
> In my map file i entered this in the layer object
> 
>  transparency 20
> 
> but any number from 0 to 100 works i guess
> 
> randy
> 
> --- Daniel Morissette <morissette at dmsolutions.ca>
> wrote:
> 
>>The transparency parameter is supported via PHP
>>MapScript for
>>getting/setting the value in the layer object (that
>>should be enough
>>as far as MapScript is concerned), so if it won't
>>work for you then it
>>must be because of something else.  
>>
>>I never used that feature so I don't know if it
>>requires anything
>>special in your build, or is supported only with
>>specific image formats
>>(maybe just PNG?).  By looking at the code it seems
>>that it should work
>>for any GD format.  Note that this transparency is
>>applied only between
>>layers within the map image and the resulting image
>>will still be opaque
>>in your browser.
>>
>>Hopefully someone who knows more about this new
>>transparency feature can
>>provide more details.
>>
>>Daniel
>>
>>
>>Vinko Vrsalovic wrote:
>>
>>>On Fri, Apr 12, 2002 at 10:32:35AM -0500, Steve
>>
>>Lime wrote:
>>
>>>>It is possible in the development version for
>>>
>>3.6. It now supports a
>>
>>>>"TRANSPARENCY" parameter
>>>>(at the LAYER level) that takes an integer
>>>
>>argument representing the %
>>
>>>>of transparency to use.
>>>>100 is completely opaque, 50 is 50% transparent
>>>
>>and so on. Color
>>
>>>>limitations will definitely affect
>>>>the quality of the output. The samples I've seen
>>>
>>are pretty good
>>
>>>>though. For earlier versions you're
>>>>limited to hatched fills...
>>>
>>>I tried setting the transparency parameter
>>
>>(through mapscript) like
>>
>>>this:
>>>
>>>$layer->set("transparency",90);
>>>
>>>and it appears solid.
>>>
>>>Version:
>>>
>>>[vinko at landsat vinko]#/builds/mapserver/mapserv -v
>>>MapServer version 3.7 (development) OUTPUT=PNG
>>
>>OUTPUT=JPEG OUTPUT=WBMP
>>
>>>SUPPORTS=PROJ SUPPORTS=TTF SUPPORTS=WMS_SERVER
>>
>>INPUT=EPPL7 INPUT=GDAL
>>
>>>INPUT=SHAPEFILE
>>>
>>>I know i should use 3.6-beta, but i'd like to know
>>
>>if my method is right
>>
>>>before recompiling.
>>>
>>>--
>>>Vinko Vrsalovic <vinko[@]cprsig.cl>
>>>http://www.cprsig.cl
>>
> 
> 
> __________________________________________________
> Do You Yahoo!?
> LAUNCH - Your Yahoo! Music Experience
> http://launch.yahoo.com





More information about the MapServer-users mailing list