Ticket #3648 (closed defect: fixed)

Opened 4 years ago

Last modified 4 years ago

Label now following lines with ANGLE FOLLOW

Reported by: adube Owned by: sdlime
Priority: normal Milestone:
Component: MapServer C Library Version: 5.6
Severity: normal Keywords: label, follow
Cc:

Description

Issue

With a particular set of data, I'm unable to make the labels follow the line features. My configuration used to work in the past and there seems to be plenty of space left for the labels to follow the lines.

Sample showing the issue

I will attach a sample of the data with a mapfile that shows the issue.

More infos

  • MS Version : 5.6.3
  • The line features are Multilinestring.
  • To test the sample, you can download it and read the readme.txt file for more instructions

Attachments

labels-not-following.png Download (38.8 KB) - added by adube 4 years ago.
A screenshot of the labels not quite following the line features
3648.tar.gz Download (145.7 KB) - added by adube 4 years ago.
The sample data with a mapfile that reproduces the issue
mapserver-trunk-label-fail.png Download (38.1 KB) - added by aboudreault 4 years ago.
Here's the label fail with mapserver trunk

Change History

Changed 4 years ago by adube

A screenshot of the labels not quite following the line features

Changed 4 years ago by adube

The sample data with a mapfile that reproduces the issue

follow-up: ↓ 3   Changed 4 years ago by aboudreault

Since the shapes are multilinestring... MapServer cannot assume the lines are continuous. Most of the lines are too small in length to draw the text, so the angle follow fails and the labels are only drawn at specific points.

However, it seems that there is a bad behavior using MapServer trunk. See the attached image. I'll investigate in that issue.

Changed 4 years ago by aboudreault

Here's the label fail with mapserver trunk

  Changed 4 years ago by adube

For the record, the features the sample data contains are the result of a COLLECT(the_geom) in PostGIS. Using ST_LineMerge(ST_Collect(the_geom)) instead merged the features collected, thus solved my original issue.

in reply to: ↑ 1   Changed 4 years ago by aboudreault

  • status changed from new to closed
  • resolution set to fixed

Replying to aboudreault:

Since the shapes are multilinestring... MapServer cannot assume the lines are continuous. Most of the lines are too small in length to draw the text, so the angle follow fails and the labels are only drawn at specific points. However, it seems that there is a bad behavior using MapServer trunk. See the attached image. I'll investigate in that issue.

Fixed and committed in r10837.

Note: See TracTickets for help on using tickets.