Change image resolution in mapfile
Ed McNierney
ed at TOPOZONE.COM
Wed Jan 25 14:20:28 PST 2006
Krishna -
I suspect that fatal error is coming from your browser or Web server; I
don't think the MapServer CGI cares how long it runs, and we certainly
run it for more than 30 seconds all the time.
JPEG is a good choice for photographic imagery; it is not a good choice
for vector maps, and PNG or TIFF would be better. If you're using JPEG
you can control the quality/compression of the output image with an
OUTPUTFORMAT block in your map file, such as:
OUTPUTFORMAT
NAME jpeg80
DRIVER "GD/jpeg"
FORMATOPTION "QUALITY=80"
END
Set QUALITY=n where n is from 1 to 100. 80 is a good estimate if you
want high-quality output at a moderate image size. If your "aliasing
effect" is happening on text on top of a photo, you may want to think of
the output as "vector" instead. Choosing PNG or TIFF will always give
you the best possible output image quality (provided you get the pixel
depth correct) because they are uncompressed. For photos they will give
you huge files, but this sounds like a one-shot deal where the final
file size doesn't really matter.
- 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: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On
Behalf Of krishna S
Sent: Wednesday, January 25, 2006 4:59 PM
To: MAPSERVER-USERS at LISTS.UMN.EDU
Subject: Re: [UMN_MAPSERVER-USERS] Change image resolution in mapfile
Thanks for all your replies guys ........
I was trying to create a 24" X 24" map with a 300 dpi thats 7200X7200
pixels map. I set the size to this pixels, when i run the mapserver it
gives me an error saying "Fatal error: Maximum execution time of 30
seconds exceeded " but it generated the map with the resolution that i
gave and the map is pretty good looking except it has some aliasing
effect which i am working on now, the image format i used is JPEG. I
guess this what i have to do ....
ultimately i need to convert this wall map into pdf form for the clients
....
Thanks again for all your time guys ...
More information about the MapServer-users
mailing list