Help with displaying a single RASTER image

Ethan Alpert ealpert at DIGITALGLOBE.COM
Fri Oct 1 15:16:25 EDT 2004


Make sure the units/projection of your geotiff are the same as your
EXTENT.

Gdalinfo is your friend....



-----Original Message-----
From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On
Behalf Of Bob Bruce
Sent: Friday, October 01, 2004 1:04 PM
To: MAPSERVER-USERS at LISTS.UMN.EDU
Subject: [UMN_MAPSERVER-USERS] Help with displaying a single RASTER
image


I am reviewing the tutorial and re-learning the MapServer by looking
over work that I had done previously on another computer and converting
examples that I had done with my own data (and that previously worked)
to the new paths on this computer. Now I am finding that I cannot get
the server to display a single GeoTIFF image under some vector data. I
can see the vector data but the raster image won't draw for some reason.
I hope that someone out there has some suggestion as to why the raster
isn't appearing. I have checked my path to the raster data and it is
correct. I have tried settings with processing the COLOR_MATCH_THRESHOLD
and it didn't work. I even tried turning off INTERLACE in the map image
and it didn't work.

The strange thing is that when I jump ahead to an example that I had
done with image tiles, this works and displays the raster tiles. But I
can't seem to get it to work with a single image. I also can't get the
raster in the standard tutorial35 to display.

Does anyone out there have an answer to my problem?

My MapServer configuration is:

C:\Apache\htdocs\MapserverTutorial>..\CGI-BIN\MAPSERV.EXE -v MapServer
version 4.2.3 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=PDF
OUTPUT=SWF SUPPORTS=PROJ SUPPORTS=FREETYPE SUPPORTS=WMS_SERVER
SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT
INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE

My map file is:

NAME T12R02E_s2ex2
EXTENT 620000 5535000 631000 5547350
SIZE 400 400
# SHAPEPATH "C:/Apache/htdocs/MapserverTutorial/TilesWWinnipeg/t12r02e"
SHAPEPATH "C:/Apache/htdocs/MapserverTutorial/TilesWWinnipeg"

OUTPUTFORMAT
  NAME png
  DRIVER "GD/PNG"
  MIMETYPE "image/png"
  IMAGEMODE PC256
  EXTENSION "png"
  FORMATOPTION "INTERLACE=OFF"
END

IMAGETYPE png

LAYER # Single ortho image display
  NAME "6205531GeoTIFF"
  DATA "t12r02e/orthodata/6205531G.tiff"
#  STATUS DEFAULT
  TYPE RASTER
  STATUS ON
  PROCESSING "SCALE=AUTO"
#  OFFSITE 0 0 0
  PROCESSING "COLOR_MATCH_THRESHOLD=8"
END

LAYER # DLS Polys
  NAME "DLSPolys"
  DATA t12r02e/t12r02ev03_DLSPolygons
  STATUS DEFAULT
  TYPE POLYGON
  CLASSITEM "PART"
  CLASS # Whole DLS Parcel
    STATUS OFF
    NAME "WHOLE DLSPOLY"
    EXPRESSION ""
    COLOR 255 202 149
    OUTLINECOLOR 0 0 0
  END # end of Whole DLS Parcel class object
  CLASS # Part DLS Parcel
    NAME "PART DLSPOLY"
    EXPRESSION "PT"
    COLOR 255 164 72
    OUTLINECOLOR 0 0 0
  END # end of Part DLS Parcel class object
END # end of layer object

LAYER # Plan Parcel Layer
  NAME "Plan Parcels"
  DATA t12r02e/t12r02ev03_LotPolygons
  STATUS DEFAULT
  TYPE POLYGON

  CLASSITEM "PART"
  CLASS # Whole Plan Parcels
    NAME "Whole Plan Parcels"
    EXPRESSION ""
    COLOR 212 178 176
    OUTLINECOLOR 0 0 0
  END # end of Whole Plan Parcels class
  CLASS # Part Plan Parcels
    NAME "Part Plan Parcels"
    EXPRESSION "PT"
    COLOR 170 103 100
    OUTLINECOLOR 0 0 0
  END # end of Whole Plan Parcels class
END  # end of water features layer

END # end of map file

and the line in my HTML file that runs the MapServer is:

<img border="1"
src="/cgi-bin/mapserv.exe?map=C:/Apache/htdocs/MapserverTutorial/TilesWW
innipeg/s2/t12r02e-ex2.map&mode=map">

thanks in advance for your help.

 Bob Bruce



More information about the mapserver-users mailing list