[mapserver-users] No errors, but no lines on output map.
Ben Logan
ben at wblogan.net
Fri Apr 5 10:09:11 PST 2002
Hello,
I am just getting started with mapserver and am trying a very simple
setup to begin with. My HTML files are modified versions of the
Itasca demo files, and so is the map file (which I've included below).
My data source is a single county's worth (Carroll county VA) of
Tiger/LINE 2000 files. I compiled mapserver with projection support
and OGR support, and the log doesn't show any errors when I run it.
However, I don't get any lines in the output map. I also had this
problem with a shapefile I was playing with, and think it is some sort
of extents problem. The values for the map's extents (shown in the
mapfile) are known to fall within the county I'm messing with.
(Aren't Tiger/LINE files in lat/lon format? The extents I placed in
my mapfile are in UTM/Meters.) I'm trying to generate a street map of
the county, but I'm not sure I'm going about it in the correct way at
all. :)
How do I get the values I need for the map EXTENT? I was also
wondering how to generate a reference image for the TIGER data.
BTW, mapserv takes awhile to serve the data up when I specify layer 0
in the CONNECTION arg, so it seems to be doing something with the
data.
#
# Start of map file
#
NAME TEST
STATUS ON
SIZE 600 600
#EXTENT -80 30 -81 40
EXTENT 533455 4053115 544725 4067075
UNITS METERS
SHAPEPATH "data"
IMAGECOLOR 255 255 255
# you may need to change this to match your MapServer build
#IMAGETYPE PNG
#
# Projection definition, consult the PROJ.4 documentation for parameter discussion
#
#PROJECTION
# "proj=utm"
# "ellps=GRS80"
# "zone=15"
# "north"
# "no_defs"
#
# OR:
#
# "init=epsg:26915"
#END
#
# Start of web interface definition (including WMS enabling metadata)
#
WEB
HEADER test_header.html
TEMPLATE test.html
FOOTER test_footer.html
LOG "test.log"
MINSCALE 1
MAXSCALE 400000
IMAGEPATH "set in test_init.html"
IMAGEURL "set in test_init.html"
METADATA
WMS_TITLE "A test map."
WMS_ABSTRACT "This is a test."
WMS_ACCESSCONSTRAINTS none
# change this value to match your setup
WMS_ONLINERESOURCE "http://mach1.log.cabin/ben/mapserv_demo/test/test_init.html"
WMS_SRS "EPSG:26915"
END
END
QUERYMAP
SIZE 200 200
STATUS ON
STYLE HILITE
COLOR 255 0 0
END
#
# Start of reference map
#
#REFERENCE
# IMAGE 'graphics/ref.png'
# #EXTENT -64 17 170 72
# EXTENT 533455 4053115 544725 4067075
# SIZE 120 120
# STATUS ON
# COLOR -1 -1 -1
# OUTLINECOLOR 255 0 0
#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 255 0
SIZE tiny
END
STYLE 1
SIZE 80 2
COLOR 0 0 255
UNITS MILES
INTERVALS 1
TRANSPARENT TRUE
STATUS TRUE
END
#
# Start of symbol definitions (we're only using a few)
#
SYMBOL
NAME 'circle'
TYPE ELLIPSE
POINTS 1 1 END
FILLED TRUE
END
#
# Start of layer definitions
#
LAYER
NAME "Carroll"
TYPE LINE
STATUS ON
CONNECTIONTYPE OGR
CONNECTION "data/carroll, 1"
#CLASSITEM 'STATES'
CLASS
NAME "Carroll"
#EXPRESSION /.*/
OUTLINECOLOR 128 128 128
COLOR 225 0 0
END
END
END # Map File
Thanks for your help,
Ben
--
Ben Logan: ben at wblogan dot net
OpenPGP Key KeyID: A1ADD1F0
More information about the MapServer-users
mailing list