[mapserver-users] Figuring out pixel size for .wld and raster imags

Ed McNierney ed at topozone.com
Fri Sep 20 08:26:54 PDT 2002


I expect those JPEGs will be blank.  Your EXTENTS statement in the map file has the minimum Y and maximum Y values reversed.

	- Ed

-----Original Message-----
From: stevek at avernus.net [mailto:stevek at avernus.net]
Sent: Friday, September 20, 2002 11:21 AM
To: Ed McNierney
Cc: stevek at avernus.net; mapserver-users at lists.gis.umn.edu
Subject: RE: [mapserver-users] Figuring out pixel size for .wld and
raster imags


Ed,

Thanks for your help.

The files are definitely getting created: I see
test103252842154626.jpg and a whole raft of others in that
directory. They are however much smaller in size (2752 bytes)
than the original image (2ish Mb), which is what is making me think
there is some problem with actually generating the image.

Niall

> Steve -
>
> You may be looking in the wrong place.  You need to distinguish between
> MapServer correctly generating a valid image that's NOT what you think
> it should be, MapServer failing to create an image at all, and
> MapServer creating an image that you cannot access from the Web.
>
> Are JPEG images being created in the /mapserv/ directory?  If not, then
> you probably have a permissions problem that prevents MapServer from
> writing to that directory.  If there are JPEGS there, then you probably
> have a Web permissions problem that prevents those images from being
> viewed by a browser (or your URL is not correctly mapped to that
> /mapserv/ directory).
>
> If you get your browser to display valid, blank images, THEN you should
> worry about your world files.
>
> 	- Ed
>
> Ed McNierney
> President and Chief Mapmaker
> TopoZone.com / Maps a la carte, Inc.
> 73 Princeton Street, Suite 305
> North Chelmsford, MA  01863
> ed at topozone.com
> (978) 251-4242
>
>
> -----Original Message-----
> From: stevek at avernus.net [mailto:stevek at avernus.net]
> Sent: Friday, September 20, 2002 10:41 AM
> To: mapserver-users at lists.gis.umn.edu
> Subject: [mapserver-users] Figuring out pixel size for .wld and raster
> imags
>
>
> Hi all,
>
> I'm having problems getting mapserver to produce anything other than a
> 28x30 broken image. I'm working currently with a raster image,
> just trying to get it to even display, never mind actually putting
> points up.
>
> My raster image is as follows:
> orig.tiff TIFF 1445x1044 DirectClass 8-bit 2474Kb 1.3u 0:02
>
> I know the GPS co-ordinates of the top left and bottom right:
> Top left is: -6.430508, 53.432611
> Bottom right is: -6.065211, 53.263772
>
> Does this mean the pixel size is as follows?
> X pixel size: -0.000257
> Y pixel size: 0.000005
>
> Here is my world file:
> -0.000257
> 0.0
> 0.0
> 0.000005
> -6.424875
> 53.26377
>
> Here is my map.map file:
> NAME test
> STATUS on
> SIZE 600 600 # set size of output image
> EXTENT -6.430508 53.432611 -6.065211 53.263772
>
> UNITS DD
> SHAPEPATH "data"
> IMAGECOLOR 255 255 255                  # set background colour of
> image IMAGETYPE jpeg
>
> #
> # Start of web interface definition
> #
> WEB
> LOG "./mapserv.log"
> TEMPLATE template.html
> IMAGEPATH "./mapserv/"
> IMAGEURL "/mapserv/"
> METADATA
>  WMS_TITLE "testing"
>  WMS_ABSTRACT "abstract"
>  WMS_ACCESSCONSTRAINTS none
>  WMS_ONLINERESOURCE "http://www.foobar.org/test"
> END
> END
>
> SCALEBAR
> IMAGECOLOR 255 255 255
> LABEL
>  COLOR 0 0 0
>  SIZE SMALL
> END
> SIZE 350 5
> COLOR 255 255 255
> BACKGROUNDCOLOR 0 0 0
> OUTLINECOLOR 0 0 0
> UNITS MILES
> INTERVALS 5
> STATUS on
> END
>
> LAYER
>  NAME "map1"
>  TYPE RASTER
>  STATUS OFF
>  DATA "orig.tiff"
> CLASS
>  NAME "Map1"
>  END
> END
>
> END
>
> Steve Kennedy






More information about the MapServer-users mailing list