Ticket #87 (new defect)

Opened 5 months ago

Last modified 5 months ago

ShieldSymbolizer on a point hangs mapnik

Reported by: kleptog Owned by: artem
Milestone: Component: Core Library
Version: 0.5.0 Severity: Normal
Keywords: Cc: kleptog@…

Description

As posted to the list, using a ShieldSymboliser? on a point hangs mapnik in agg::path_length. Attached are three patches, any two of which solve the problem:

patch1: This fixes the underlying problem. When a vertex is used as a VertexSource?, it never returns an end-of-object marker and so loops forever. Since a vertex only has one point it should return END. Or should it return the point with MOVETO and then END. Someone needs to check this.

patch2: First the length is calculated and stored in total_distance, subsequently the variable distance is tested. I have no idea where this variable is defined, so I think it's a typo.

patch3: Given that I don't know if patch1 is correct, here is patch3, which adds a test to path_length to return 0 immediatly if there are only 0 or 1 nodes. But this requires adding a num_points function. I'm not sure if this is the right solution. In the end I am unsure what is the right solution. Currently I use all the above and everything seems to be working fine.

Attachments

patch1.txt (399 bytes) - added by kleptog 5 months ago.
patch2.txt (487 bytes) - added by kleptog 5 months ago.
patch3.txt (0.8 kB) - added by kleptog 5 months ago.

Change History

Changed 5 months ago by kleptog

Changed 5 months ago by kleptog

Changed 5 months ago by kleptog

Changed 5 months ago by kleptog

  • component changed from Boost.Python Binding to Core Library
Note: See TracTickets for help on using tickets.