request for new mapserver features

Frank Warmerdam warmerdam at POBOX.COM
Mon Apr 24 10:21:32 EDT 2006


Peter Freimuth (MapMedia GmbH) wrote:
> Dear mapserver-dev Team,
> in context of using mapserver to generate a digital nautical mapchart 
> out of s57 data (imported into postgres/postgis), we found two missing  
> features to solve this task. Both features can be useful in a lot of 
> other areas.
> - new feature type ARC, defined by:
> STARTANGLE in Degree (west=0/360, north = 90 ,east=180,south=270)
> ENDANGLE in degrees or ARCANGLE (negative value means clockwise 
> direction) in degrees
> RADIUS (meter, miles or whatever)
> The feature can be used in the same manner as every other line or 
> polygon feature. GD supports drawing of arcs so it should be not a big 
> problem to introduce the parameters in the mapfileparser and to handle 
> this featuretype inside of the current drawing routines.

Peter,

Adding an Arc would make me very nervous.
  o It would require changes in all the rendering drivers (GD, SWF, PDF, etc)

  o How does one reproject an arc?

  o It has no WKT analog for the conversion functions.

  o it does not easily fit into the existing shapeObj idea of a list of
    lines each of which is a list of points.

For many purposes we would end up having to approximate the arc as
a linestring, so why not treat it that way from the start?  At the very
least I believe adding it would be a significant complication for
geometry handling in mapserver.

> - draw a symbol at the center of polygons or lines (it is possible for 
> labels so why not using the label offset point for symbol placement in 
> the same way); it is possible to solve this inside of PostGIS, but i 
> think it would also be a nice function for other datasources.

This seems quite reasonable to me, though I don't know the details of
what would be needed to implement it.  If you are so inclined, perhaps you
could prepare a patch implementing this.  If it is non-disruptive Steve
could likely commit it without further complication.  If it requires any
sort of changes to mapfile syntax or has other possible compatibility
issues an RFC would likely be needed.

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 OSGF, http://osgeo.org



More information about the mapserver-dev mailing list