[MapServer-users] Who remembers the truth about antialiasing?

Lime, Steve D (MNIT) steve.lime at state.mn.us
Wed Nov 15 13:16:35 PST 2023


Looking at the code, the keyword is still in place in 8.0. It is recognized in the STYLE object but is silently ignored inside a LABEL object. I didn't check rendering code specifically to see what true vs false values affected. So, I think your conclusions are correct.

From: MapServer-users <mapserver-users-bounces at lists.osgeo.org> On Behalf Of Rahkonen Jukka via MapServer-users
Sent: Wednesday, November 15, 2023 12:59 PM
To: Mapserver-Users (mapserver-users at lists.osgeo.org) <mapserver-users at lists.osgeo.org>
Subject: [MapServer-users] Who remembers the truth about antialiasing?

Hi,

When Mapserver started to use AGG renderer everybody thought that antialiasing is not only the strength of the library but also the only way AGG can render. See https://mapserver.org/output/agg.html and https://lists.osgeo.org/pipermail/mapserver-users/2007-September/025467.html.
But then some Mapserver users noticed that AGG (and Mapnik) can also do aliased rendering at least for lines. Discussion on the mailing list https://lists.osgeo.org/pipermail/mapserver-users/2017-October/080278.html yielded a GitHub issue https://github.com/MapServer/MapServer/issues/5508 and a commit https://github.com/erik-h11/mapserver/commit/9ca99e763738fba7acaea6089afb5b5b7cd6e699.

However, the Mapserver documentation is unclear https://mapserver.org/mapfile/style.html#mapfile-style-antialias. I understand it so that setting antialias has not been functional since 7.0, and in 8.0 the whole keyword was removed.

"ANTIALIAS [true|false]
Removed in version 8.0: GD support was removed in 7.0 (and this mapfile parameter was removed in 8.0)
Should antialiasing be applied to the style. For line rendering only. Default is false."

My conclusions at the moment are:

  *   ANTIALIAS true|false does work in STYLE. It affects only lines, but polygon outlines are also lines. The default is TRUE.
  *   ANTIALIAS does not have an effect in other places: LABEL and SYMBOL. They are always antialiased.

If that is correct I may have a try with improving the documentation.

I started to experiment with antialias because I was not very satisfied with a very simple map that has only lines and labels. For my mind the lines on that map look better without antialiasing. Unfortunately I could not do anything for the labels. Especially dashes turn out light grey and blurry. The font is truetype, Vera, and the text color in the mapfile is pure black. All hints for making labels sharper are welcome.
[cid:image001.png at 01DA17CC.42C69A10]

-Jukka Rahkonen-



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20231115/c8e54c2c/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.png
Type: image/png
Size: 1644 bytes
Desc: image001.png
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20231115/c8e54c2c/attachment.png>


More information about the MapServer-users mailing list