[Mapserver-users] Mapserver Raster Images/Extents Newbie questions (Sorry!)

James Martin martin426 at yahoo.com
Sat Jun 19 10:25:16 PDT 2004


Hello,

I'm pretty new with this application, so any help with
these three questions would be appreciated.

My first question is regarding the Extent declaration.
 Can I declare this in Lat/Long format somehow?  I've
been toying with cs2cs to convert by invoking: 

cs2cs +init=epsg:4326 +to +init=epsg:2163 -v

Except the returned values seem quite random, and I
don't get the results I'm expecting.  If I can't use
Lat/Long, is there any good documentation for cs2cs
that you know of?  (It seems that the remotesensing
site where a lot of this is hosted is down) Trying to
find the range enclosed by 180W 90N and 180E 90S (ie:
The whole world) gives me nonsensical values.

*******

My second question is regarding raster images.  Here
is the output of mapserv -v:

MapServer version 4.0 OUTPUT=PNG OUTPUT=JPEG
OUTPUT=WBMP SUPPORTS=PROJ SUPPORTS=FREETYPE
SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT
SUPPORTS=WFS_CLIENT INPUT=TIFF INPUT=EPPL7 INPUT=JPEG
INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE

Here is the output of gdal-config --formats:

gxf gtiff hfa aigrid aaigrid ceos ceos2 iso8211 bsb
xpm sdts raw dted mem jdem envisat elas fit vrt
usgsdem l1b nitf bmp gif jpeg png grass

Using the following mapfile I get no output of the
raster image... The states display as expected, and
both data sets are in the same directory, so I'm
thinking something else must be wrong but there is no
indication as to what (Note: this is the example from
the mapserver homepage regarding raster images):

MAP
    STATUS ON
    IMAGETYPE PNG
    SIZE 800 500
    SHAPEPATH "data"
    EXTENT -6086744.000 -2784127 4278894 4485901

  PROJECTION
    "proj=laea"
    "ellps=clrk66"
    "lat_0=45"
    "lon_0=-100"
  #
  # Alternatively, you can specify an EPSG code.
  # "init=epsg:2163"
  #
  END

  LAYER
     NAME NightLights
     DATA nitelti020l
     TYPE RASTER
     STATUS ON
  END

  LAYER # States polygon layer begins here
    NAME         states
    DATA         statesp020
    STATUS       DEFAULT
    TYPE         POLYGON

    PROJECTION
      "init=epsg:4326"
    END

    CLASS
      NAME "US states"
      OUTLINECOLOR 50 50 50
      SYMBOL 0
    END
  END # States polygon layer ends here
END # end of map file/object

***********

My third question is regarding world files, however it
won't matter until I can get images to work.  I've got
several of the NASA blue marble images that represent
the entire planet.  They vary in size but for this
example we'll say I'm using the 8192x4096 version. 
Pixel 1,1 represents 180W 90N, pixel 8192,4096
represents 180E 90N.  What would the world file look
like for this and what process do you follow to come
up with it?  Again, can I use lat/long coordinates?

***

One last thing--Is there a good intro tutorial to
epsg, and what all these other formats for coordinate
systems are?  

Many Thanks,

James
Atlanta, GA


		
__________________________________
Do you Yahoo!?
Yahoo! Mail is new and improved - Check it out!
http://promotions.yahoo.com/new_mail



More information about the MapServer-users mailing list