You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@szekerest reported instances where labeling where thin, simple polygons (think parcels) results in label points outside a polygon. It happens because a edge/distance computation in msPolygonLabelPoint() done after a center of gravity computation drops the label point computation into a second algorithm that uses scan lines to place the label. There is a bug in that second computation that can result in bad label placement.
The fix is easy, simply uncomment a couple of lines in that function, look for:
/* lp->y = y; */
/* lp->x = x; */
and the issue is resolved. In cases like this it might be even better to skip the distance check or at least make that more robust, but that's another ticket. I tried allowing a configuration via a layer processing option but since label placement is independent of layer properties it's not trivial to make that value available, especially with MapScript.
The text was updated successfully, but these errors were encountered:
sdlime
added a commit
to sdlime/mapserver
that referenced
this issue
Feb 5, 2016
@szekerest reported instances where labeling where thin, simple polygons (think parcels) results in label points outside a polygon. It happens because a edge/distance computation in msPolygonLabelPoint() done after a center of gravity computation drops the label point computation into a second algorithm that uses scan lines to place the label. There is a bug in that second computation that can result in bad label placement.
The fix is easy, simply uncomment a couple of lines in that function, look for:
and the issue is resolved. In cases like this it might be even better to skip the distance check or at least make that more robust, but that's another ticket. I tried allowing a configuration via a layer processing option but since label placement is independent of layer properties it's not trivial to make that value available, especially with MapScript.
The text was updated successfully, but these errors were encountered: