[Mapserver-users] Nothing raster (tiff,jpeg) comes out

Vincent Schut schut at sarvision.com
Tue Aug 5 00:28:02 PDT 2003


Zainal,

I see that you use 'status on', I do not know if this is for the entire map 
thing or just in the layer. Mind that - this is tricky, I know, many of us 
stumbled on it when we begun mapserving - when using mapserver cgi, status on 
means that you will have to explicitly mention the layers you want to be 
visible in your url request (like 
http://blabla/mapserv/map=foo&mode=map&layer=oceanc&...). Status works like 
this: status off means you cannot show a layer, even when explicitly 
requesting it in your url. The layer is more or less non-existent according 
to the mapserv process. Status on means the layer is there and ready to be 
rendered *on request*. Status default means the layer will be rendered 
*always*. So if you wonder why your layer does not appear, setting status to 
default is always a good thing to do. Then you know for sure that it's not 
the status thingy that breakes your mapping.

BTW working without worldfiles when using rasters that do not have any 
geocoding info inside (like normal tiff, gif, jpeg, etc) will only work when 
you set your extent accordingly as an x-y projection, I think something like 
'extent 0 0 1024 800' if your image is 1024 by 800 pixels. Could be that you 
need to start at 1 1. As soon as you are defining a projection, your extent 
will need to be in coordinates matching that projection (and also your 
units), and you will need the right coordinates with your raster files, like 
inside a geotiff (or another geocoding enabled format) or using a world file 
(filename.wld will do for all image file formats).

Cheers,
Vincent.

On Tuesday 05 August 2003 01:36, Siki Zoltan wrote:
> Hi Zainal,
>
> On Mon, 4 Aug 2003, zainal A Majeed wrote:
> > I appreciate your response. I have checked again everything as you
> > suggested. It does support raster as I tried the raster image in
> > mapserver tutorial all this while.
> > I am using .tiff and convert to .img after image proceesing then to .jpg.
> > I don’t need World file for the time being.
>
> If you don't have gdal installed you can use only 256 colors!
> Convert your image to 256 color palette if it has more colors.
>
> I have never used images without world file, I think you must have
> world file or geotiff.
> The world file is an ascii file you can easy create it. A world file
> consist of 6 lines, each line contains a single value.
> 1st line: pixel size in x direction in meters (or foot or ...)
> 2nd line: 0 if the coordinate system paralel to the image
> 3rd line: 0 if the coordinate system paralel to the image
> 4th line: -pixel size in y direction in meter (negativ value)
> 5th line: easting for upper left corner
> 6th line: northing for upper left corner
> What extents do you specify in the map file without a world file?
>
> > The status is ON and when display in IE I can right click to copy to wall
> > paper or desktop background but it’s invisible (white image).
>
> Yeh, you got an empty image from the mapserver.
>
> Do you have a html template? If yes, then you can can check mapext cgi
> variable inserting [mapext] somewhere in the html code.
>
> Have you read raster-howto?
> Visit the galery to get idea.
> Finally insert your map and template file into your mail.
>
> Hi
> Zoltan
>
> > >===== Original Message From Siki Zoltan <siki at bme-geod.agt.bme.hu> =====
> > >Dear Zainal,
> > >
> > >You gave us few details, so I can make only suggestions.
> > >
> > >Does mapserver support the used raster format?
> > >Check mapserv -v
> > >
> > >Do you have world file along with your raster image?
> > >If you have GeoTiff no need for world file.
> > >See Raster howto at mapserver.gis.umn.edu/doc36/raster-howto.html
> > >
> > >What is the status of the layer?
> > >If it is ON then you will see it if you specify the layer name in the
> > >query string e.g.
> > >www.somewhere/cgi-bin/mapserv?map=your_map_file&layer=layer_name
> > >
> > >Does the extent of the map and the raster fits?
> > >
> > >If these don't help give us more information.
> > >
> > >Hi,
> > >Zoltan Siki
> > >
> > >On Fri, 18 Jul 2003, zainal A Majeed wrote:
> > >> Dear friends,
> > >>
> > >> I hope this is not a repetition. I try to map out with mapsever raster
> >
> > aerial
> >
> > >> photo from map file. The connection to mapserver was alright but
> > >> nothing
> >
> > comes
> >
> > >> out in view except white window(there is an image but white - can't
> > >> see). Can anybody tell what is the problem?
> > >>
> > >> Thanks and cheers
> > >>
> > >> Zainal
> > >>
> > >> ZAINAL A MAJEED
> > >> PhD in Web Technology and Internet GIS
> > >> School of Civil Engineering and Geosciences
> > >> Bedson BUilding, University of Newcastle upon Tyne
> > >> Newcastle upon-Tyne NE1 7RU
> > >> United Kingdom
> > >>
> > >> Tel: +44 (0)191 222 6357
> > >> Fax: +44 (0)191 222 8691
> > >> email: zainal.abdul-majeed at ncl.ac.uk
> > >> web: http://www.cegs.ncl.ac.uk
> > >> web: http://geomatics.ncl.ac.uk
> > >> *************************************
> > >> Home:
> > >> 178 Dilston Road,
> > >> Newcastle Upon Tyne NE4 5AD
> > >> United Kingdom
> > >> Phone  : +44 (0) 191-2727259
> > >> Mobile : +44 (0) 796-0938952
> > >>
> > >> _______________________________________________
> > >> Mapserver-users mailing list
> > >> Mapserver-users at lists.gis.umn.edu
> > >> http://lists.gis.umn.edu/mailman/listinfo/mapserver-users
>
> _______________________________________________
> Mapserver-users mailing list
> Mapserver-users at lists.gis.umn.edu
> http://lists.gis.umn.edu/mailman/listinfo/mapserver-users

-- 
______________________________________
Vincent Schut
Sarvision B.V.
Wageningen, The Netherlands
www.sarvision.com




More information about the MapServer-users mailing list