Spam: Re: [UMN_MAPSERVER-USERS] Strange imagetype/outputformat behaviour

Dejan Gambin dejan.gambin at PULA.HR
Sun Jul 15 09:13:46 EDT 2007


Frank,

I am using MS4W and p.mapper framework. The request is very simple - I have
a raster layer made by tileindex shape file, like this:

LAYER # raster
  NAME         "ortofoto"
  GROUP	       "ortofoto"
  STATUS       ON
  TYPE         RASTER
  METADATA 
    "DESCRIPTION" "Ortofoto"
  END
  TILEINDEX "vodnjan"
  TILEITEM "LOCATION"
    CLASS
    Name 'ortofoto'
    COLOR 51 102 160
    OUTLINECOLOR 0 0 0 
    TEMPLATE void
  END
END 

Maybe I need to look in the p.mapper somewhere and debug the requests...I'll
try...

regards, dejan

> -----Original Message-----
> From: UMN MapServer Users List 
> [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of Frank Warmerdam
> Sent: Saturday, July 14, 2007 4:05 PM
> To: MAPSERVER-USERS at LISTS.UMN.EDU
> Subject: Re: [UMN_MAPSERVER-USERS] Spam: Re: 
> [UMN_MAPSERVER-USERS] Strange imagetype/outputformat behaviour
> 
> Dejan Gambin wrote:
> > Frank,
> > 
> > No the declarations are not nested, I just made a mistake while 
> > pasting it in the message.
> > 
> > I am trying to use a custom outputformat. I set something like:
> > 
> > IMAGETYPE "custom"
> > OUTPUTFORMAT
> >   NAME "custom"
> >   DRIVER "GD/PNG"
> >   MIMETYPE "image/png"
> >   IMAGEMODE RGB
> >   FORMATOPTION  INTERLACE=OFF
> >   TRANSPARENT OFF
> > END
> > 
> > ...the resulting display is lower color quality than the 
> first one and 
> > the image size is 53KB. I tried the same without the 
> quotation marks, 
> > it is the same. Then I have tried different combinations 
> using DRIVER 
> > "GDAL/PNG", nothing works...then I tried using IMAGETYPE 
> png without 
> > having OUTPUTFORMAT png defined - the same. But when I 
> replace both and set:
> > 
> > IMAGETYPE png
> > OUTPUTFORMAT
> >   NAME png
> >   DRIVER "GD/PNG"
> >   MIMETYPE "image/png"
> >   IMAGEMODE RGB
> >   FORMATOPTION  INTERLACE=OFF
> >   TRANSPARENT OFF
> > END
> > 
> > ...the resulting display is better color quality and the 
> image size is 
> > 303KB !
> > 
> > So I really don't understand what is happening. I am using MS4W. 
> > Mapserv.exe -v shows:
> > 
> > MapServer version 4.10.0 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG 
> OUTPUT=WBMP 
> > OUTPUT=PDF OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=FREETYPE 
> > SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER 
> > SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER 
> > SUPPORTS=THREADS SUPPORTS=GEOS INPUT=JPEG INPUT=POSTGIS INPUT=OGR 
> > INPUT=GDAL INPUT=SHAPEFILE DEBUG=MSDEBUG
> > 
> > The problem is that I don't know if the "better display result" is 
> > indeed the best one I can get...
> 
> Dejan,
> 
> What sort of requests are you making to mapserv? Perhaps the 
> custom format isn't working because you are overriding the 
> format in the mapserv request?  (for instance with the 
> FORMAT= flag in WMS requests).
> 
> Other than that, I don't see any explanation for what is happening.
> 
> Best regards,
> 
> -- 
> ---------------------------------------+----------------------
> ----------
> ---------------------------------------+------
> I set the clouds in motion - turn up   | Frank Warmerdam, 
> warmerdam at pobox.com
> light and sound - activate the windows | http://pobox.com/~warmerdam
> and watch the world go round - Rush    | President OSGeo, 
> http://osgeo.org
> 



More information about the mapserver-users mailing list