[mapserver-users] Change Background Image Color Dynamically

Fawcett, David David.Fawcett at state.mn.us
Mon Mar 9 09:33:43 EDT 2009

By adding '&map.imagecolor=255+255+255' to your URL string, you will
change the background color to white.  At least for MapServer versions
of 5.2 or greater.  The trick will just be to keep track of the map
scale in your client and add the imagecolor substitution at the
appropriate scales.

	-----Original Message-----
	From: mapserver-users-bounces at lists.osgeo.org
[mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Bill Thoen
	Sent: Monday, March 09, 2009 9:12 AM
	To: mapserver-users at lists.osgeo.org
	Subject: [mapserver-users] Change Background Image Color
	I've got a layer of USGS DRG's where I set the OFFSITE parameter
to black to hide the excess bitmap at the edges of the DRGs. But this
also makes black lines , text and other black graphic elements IN the
map as transparent, washing them out. So I set IMAGECOLOR to black to
sharpen them up. 
	However, at scales beyond those appropriate for the DRGs I want
to set the background color back to white. So is there some way that I
can either use a black background only when the DRG layer is visible, or
dynamically change the background color as the map scale changes?
	- Bill Thoen

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/mapserver-users/attachments/20090309/f4396d15/attachment.html

More information about the mapserver-users mailing list