[Mapserver-users] Setting transparency via CGI
Havard Tveite
havard.tveite at ikf.nlh.no
Mon Mar 31 03:15:19 PST 2003
In my latest build of mapserver (3.7 dev 19 march 2003, gdal, gd2) it
does not seem to be possible to set the layer TRANSPARENCY parameter via
CGI.
Is this possible in the latest build? If not, is there a reason why?
I wanted the user to be able to supply a transparency value for a layer
called "testlayer" from a menu, resulting in the following parameter
being sent to mapserver:
map_testlayer_transparency=50
This can be very useful for orthofotos (e.g. satellite images or arial
photograps), but can also be useful for vector layers.
In order for this parameter to have effect, the outputformat will have
to have support for transparency.
Something like the following could be added to the switch in
mapfile.c - loadLayerString( ... )
case (TRANSPARENCY):
/* Should we check if transparency is supported by outputformat or
if transparency for this layer is already set??? */
msyystate = 2; msyystring = value;
if(getInteger(&(layer->transparency)) == -1) return;
break;
--
Håvard Tveite Phone: +47 64948857
Department of Mapping Sciences Fax: +47 64948856
Agricultural University of Norway http://www.nlh.no/ikf
Hogskoleveien 14, POBox 5034, N-1432 Ås, NORWAY
More information about the MapServer-users
mailing list