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

Frank Warmerdam warmerdam at POBOX.COM
Sat Jul 14 07:05:25 PDT 2007


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