PNG Output.
Owens, Ryan J NWD02 CONTRACTOR
Ryan.J.Owens at NWO02.USACE.ARMY.MIL
Thu Jul 21 08:11:09 PDT 2005
Bart,
Thanks for responding so quickly.
I tried both of your settings and I received the following error message,
which makes me think that Frank's response means that my version of MS is not
configured to support PNG:
loadOutputFormat(): General error message. OUTPUTFORMAT clause references
driver GD/PNG, but this driver isn't configured.
Ryan
-----Original Message-----
From: Bart van den Eijnden [mailto:BEN at Syncera-ITSolutions.NL]
Sent: Thursday, July 21, 2005 9:38 AM
To: MAPSERVER-USERS at LISTS.UMN.EDU; Owens, Ryan J NWD02 CONTRACTOR
Subject: Re: [UMN_MAPSERVER-USERS] PNG Output.
Try this for 8 bit png:
OUTPUTFORMAT
NAME png
DRIVER "GD/PNG"
MIMETYPE "image/png"
IMAGEMODE PC256
EXTENSION "png"
END
Or this for 24 bit png:
OUTPUTFORMAT
NAME png
DRIVER "GD/PNG"
MIMETYPE "image/png"
EXTENSION PNG
IMAGEMODE RGBA
TRANSPARENT ON
END
Bart
Bart van den Eijnden
Syncera IT Solutions
Postbus 270
2600 AG DELFT
tel.nr.: 015-7512436
email: BEN at Syncera-ITSolutions.nl
>>> "Owens, Ryan J NWD02 CONTRACTOR"
<Ryan.J.Owens at NWO02.USACE..ARMY.MIL> 07/21/05 04:29pm >>>
MS List Serve,
I'm having difficulty producing a PNG output from a map file I made. Here is
the error message that I am receiving: msPostMapParseOutputFormatSetup():
General error message. Unable to select IMAGETYPE `png'.
Does anyone know what this means and how I can go about fixing it? Below is
my code.
Thank you,
Ryan
#
# Start of map file
#
NAME EDOQ
STATUS ON
SIZE 600 600
# Extents from lower left to upper right (minx miny maxx maxy)
# EXTENT -545712 26685 1428199 1537062
EXTENT -110 36 -90 46
#UNITS meters
UNITS dd
#SHAPEPATH "data"
IMAGECOLOR 100 100 200
IMAGETYPE png
#IMAGEQUALITY 96
OUTPUTFORMAT
NAME jpeg
DRIVER "GD/JPEG"
FORMATOPTION "QUALITY=95"
MIMETYPE "image/jpeg"
IMAGEMODE RGB
EXTENSION "jpg"
END
#
#
PROJECTION
# MRR Albers projection
#"proj=aea"
#"Lat_1=40.3861111"
#"lat_2=47.272222"
#"lat_0=37.0"
#"lon_0=-105.685556"
#"x_0=0.0"
#"y_0=0.0"
#"ellps=clrk66"
#"datum=NAD27"
#"units=m"
"init=epsg:4326"
END
#
# Start of web interface definition (including WMS enabling metadata)
#
WEB
TEMPLATE demo.html
# MINSCALE 1000
# MAXSCALE 40000
IMAGEPATH "[edited for privacy]/"
IMAGEURL "/tmp/"
METADATA
WMS_TITLE "NWD-PDM DRG"
WMS_ABSTRACT "Water Management DRG of Omaha in TIF Format"
WMS_ACCESSCONSTRAINTS "For US Army Corps of Engineers Use Only."
WMS_ONLINERESOURCE "http://[domain
information]/cgi-bin/mapserv?map=../htdocs/mapserver/drg/drg24.map&"
WMS_SRS "EPSG:4326 AUTO:42003 "
END
END
#
# Start of scalebar
#
SCALEBAR
IMAGECOLOR 255 255 255
LABEL
COLOR 255 255 255
SIZE tiny
END
STYLE 1
SIZE 80 2
COLOR 255 255 255
UNITS MILES
INTERVALS 1
TRANSPARENT TRUE
STATUS TRUE
END
### DRG 24,000 ###
LAYER # DRG data
NAME drg24
TYPE raster
TILEINDEX "oma24kqd.shp"
MAXSCALE 40000
STATUS DEFAULT
OFFSITE 0 0 0
PROJECTION
"init=epsg:80000"
END
METADATA
WMS_TITLE "DRG24000"
WMS_ABSTRACT "DRG: MRR Albers"
WMS_OPAQUE "1"
END
END
### INDEX DRG 250 ####
LAYER
NAME drg24ki
TYPE line
DATA "oma24kqd.shp"
# MAXSCALE 40000
STATUS ON
PROJECTION
"init=epsg:80000"
END
METADATA
WMS_TITLE "indexdrg24k"
WMS_ABSTRACT "DRG: MRR Albers"
WMS_OPAQUE "1"
END
CLASS
SYMBOL 0
COLOR 185 211 238
OUTLINECOLOR 0 0 0
LABEL
TYPE bitmap
COLOR 255 255 0
OUTLINECOLOR 0 0 0
SIZE tiny
POSITION cc
WRAP "/"
END
END
END
LAYER # DOQQ data
NAME doqq24
TYPE raster
TILEINDEX "doqq.shp"
MAXSCALE 60000
STATUS DEFAULT
OFFSITE 0 0 0
PROJECTION
"init=epsg:80000"
END
METADATA
WMS_TITLE "DOQQ"
WMS_ABSTRACT "DRG: MRR Albers"
WMS_OPAQUE "1"
END
END
### INDEX DRG 250 ####
LAYER
NAME doqq24ki
TYPE line
DATA "doqq.shp"
# MAXSCALE 40000
STATUS ON
PROJECTION
"init=epsg:80000"
END
METADATA
WMS_TITLE "DOQQINDEX"
WMS_ABSTRACT "DRG: MRR Albers"
WMS_OPAQUE "1"
END
CLASS
SYMBOL 0
COLOR 185 211 238
OUTLINECOLOR 0 0 0
LABEL
TYPE bitmap
COLOR 255 255 0
OUTLINECOLOR 0 0 0
SIZE tiny
POSITION cc
WRAP "/"
END
END
END
###############################
LAYER # DOQQ data
NAME Oahe_Color
TYPE raster
TILEINDEX "oahe.shp"
MAXSCALE 60000
STATUS DEFAULT
OFFSITE 0 0 0
PROJECTION
"init=epsg:26914"
END
METADATA
WMS_TITLE "Oahe CLR"
WMS_ABSTRACT "Oahe - UTM"
WMS_OPAQUE "1"
END
END
### INDEX DRG 250 ####
LAYER
NAME Oahe_Col_IDX
TYPE line
DATA "oahe.shp"
# MAXSCALE 40000
STATUS ON
PROJECTION
"init=epsg:26914"
END
METADATA
WMS_TITLE "Oahe Index"
WMS_ABSTRACT "Oahe - UTM"
WMS_OPAQUE "1"
END
CLASS
SYMBOL 0
COLOR 185 211 238
OUTLINECOLOR 0 0 0
LABEL
TYPE bitmap
COLOR 255 255 0
OUTLINECOLOR 0 0 0
SIZE tiny
POSITION cc
WRAP "/"
END
END
END
################################
end # map file
..
More information about the MapServer-users
mailing list