[ms4w-users] PNG24 output in WMS?
Smith, Michael
Michael.Smith at maine.gov
Fri Dec 7 12:22:59 EST 2007
Map file below, running the latest version of MS4W on Windows XP Pro.
This is related to the ArcGIS interoperability question I posted a few
days ago. According to ESRI developers in charge of WMS support, the
default format supported is PNG 24-bit. However my ArcGIS (9.2 SP4)
always gets PNG 8-bit when accessing MapServer as a WMS. This makes my
aerial photos look like crap.
What configuration change is required to provide 24-bit PNG via WMS?
My map file is simply the default GMAP map file altered with WMS
parmeters and my own data.
***********
Michael Smith
Maine DEP/OIT
#
# Start of GMAP map file
#
#
NAME GMAP_DEMO
STATUS ON
SIZE 400 300
SYMBOLSET ../etc/symbols.sym
EXTENT 413000 4837000 446000 4894000
UNITS METERS
SHAPEPATH "../medata"
IMAGECOLOR 255 255 255
FONTSET ../etc/fonts.txt
OUTPUTFORMAT
NAME jpeg
DRIVER "GD/JPEG"
IMAGEMODE RGB
EXTENSION "jpeg"
FORMATOPTION "QUALITY=75,PROGRESSIVE=TRUE"
END
#
# Start of web interface definition
#
WEB
# Scales commented out for WMS
# MINSCALE 5000
# MAXSCALE 350000
#
# On Windows systems, /tmp and /tmp/ms_tmp/ should be created at the
root
# of the drive where the .MAP file resides.
#
IMAGEPATH "/ms4w/tmp/ms_tmp/"
IMAGEURL "/ms_tmp/"
# For WMS
METADATA
"wms_title" "wms_demo"
"wms_onlineresource"
"http://csu-eia1pcgis2.som.w2k.state.me.us/cgi-bin/mapserv.exe?map=c:/ms
4w/apps/gmap/htdocs/gmap75.map&"
"wms_srs" "EPSG:26919"
"wms_format" "image/jpeg"
END
END
#
# Projection - required for WMS
#
PROJECTION
"init=epsg:26919"
END
#
# Start of reference map
#
REFERENCE
IMAGE meimages/keymap.png
EXTENT 413000 4837000 446000 4894000
STATUS ON
COLOR -1 -1 -1
OUTLINECOLOR 255 0 0
SIZE 116 116
END
#
# Start of legend
#
LEGEND
KEYSIZE 18 12
LABEL
TYPE BITMAP
SIZE MEDIUM
COLOR 0 0 89
END
STATUS ON
END
#
# Start of scalebar
#
SCALEBAR
IMAGECOLOR 255 255 255
LABEL
COLOR 0 0 0
SIZE SMALL
END
SIZE 150 5
COLOR 255 255 255
BACKGROUNDCOLOR 0 0 0
OUTLINECOLOR 0 0 0
UNITS kilometers
INTERVALS 5
STATUS ON
END
QUERYMAP
STYLE HILITE
COLOR 255 0 0
END
#
# Start of layer definitions
#
LAYER
NAME naip2007
METADATA
"wms_title" "NAIP 2007"
END
TYPE RASTER
STATUS ON
DATA sagadahoc.sid
PROJECTION
"init=epsg:26919"
END
END
END # Map File
More information about the ms4w-users
mailing list