Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Backward compatibility: marker line placement for polygons converges toward center ?! #1591

Closed
strk opened this issue Nov 23, 2012 · 3 comments
Milestone

Comments

@strk
Copy link
Contributor

strk commented Nov 23, 2012

I'm not sure what's going on here:
http://strk.keybit.net/tmp/line-marker-placement-convergence.png

On the left you have mapnik-2.0.x, on the right you have mapnik-2.1.x
Uncommenting the marker-clip:false line in CartoCSS turns the rendering on the right completely blank. The input is a regular hexagonal grid.

@springmeyer
Copy link
Member

Two things are happening here:

  1. Clipping is causing the convergence issue. I'm not sure why (this deserves a separate bug report). This can be worked around by turning it off + clipping should be default off when we move on Make clipping default off for all symbolizers with custom placement #1569.

  2. The reason you get nothing rendered when clipping is off is that the marker size does not fit within the length of the line it is being placed upon. This may seem like a regression but it is actually an intentional bugfix and landed in 5bc9f73#include/mapnik/markers_placement.hpp. Now that marker size can be manipulated on the fly, you can use that functionality to test that it is the size preventing rendering. Try setting transform="scale(.5,.5)" (or in css: marker-transform:scale(.5,.5)).

So, for complete backwards compatibility an option would need to be added to ask for rendering of markers even when they do not fit within a given line segment. I'm not sure that is worth it.

@strk
Copy link
Contributor Author

strk commented Nov 27, 2012

#1553 may have a role here too ?

@strk
Copy link
Contributor Author

strk commented Nov 27, 2012

@springmeyer I confirm that scaling the symbol by 50% gets the arrows back, I'm happy with only #1553 being acted upon (if possible).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants