[mapserver-users] WMS layer is blank

Frank Warmerdam warmerdam at pobox.com
Tue Nov 19 22:00:38 EST 2002


Dylan Keon wrote:
> I successfully compiled the latest 3.7 CVS version (thanks Frank, 
> Assefa, and Daniel), and can report that this version is able to display 
> WMS layers retrieved from terraservice.
> 
> However, now I seem to be running into the 24-bit vs 8-bit problem (I 
> think).  The DOQ image retrieved directly into the browser looks great, 
> but the image retrieved and rendered by MapServer looks pretty bad. 
> Please have a look at http://www.nacse.org/~keon/temp/wms to see what I 
> mean.  Ignoring the issues about 24-bit file size vs. 8-bit, etc. for 
> the moment, any suggestions on how to get the good-looking image in my 
> interface? :-)  I'm using gd 1.8.4, would switching to 2.0.7 help?

Dylan,

If you upgrade to GD 2.x then you can use MapServer 24-bit mode.  You would
also need a declaration something like this in your mapfile:

IMAGETYPE png24

OUTPUTFORMAT
   NAME png24
   DRIVER "GDAL/PNG"
   IMAGEMODE RGB
   TRANSPARENT OFF
END

Actually, returning JPEG data (like the terraserver) might be much better:

IMAGETYPE jpeg24

OUTPUTFORMAT
   NAME jpeg24
   DRIVER "GDAL/JPEG"
   IMAGEMODE RGB
   TRANSPARENT OFF
END

I have also been considering implementing a dithering scheme in MapServer
for converting 24bit to 8bit.  Would you be willing to test it if I
implemented it?

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    | Geospatial Programmer for Rent





More information about the mapserver-users mailing list