mapbox / carto

fast CSS-like map stylesheets
https://cartocss.readthedocs.io/
Apache License 2.0
652 stars 129 forks source link

Add support for douglas-peucker simplify-algorithm #487

Closed matthijsmelissen closed 6 years ago

matthijsmelissen commented 6 years ago

Would it be possible to add support for the douglas-peucker simplify-algorithm?

It seems on the Mapnik side this is already implemented:

nebulon42 commented 6 years ago

Definitely. It needs support in mapnik-reference to be usable for CartoCSS.

matthijsmelissen commented 6 years ago

Just to be sure: at the moment it does not have support in Mapnik-reference?

nebulon42 commented 6 years ago

No, that is why it is not recognized by CartoCSS as available option. Mapnik devs do not update mapnik-reference for each feature accordingly. Sometimes something is forgotten. The upcoming 1.0 release will make CartoCSS more independent from mapnik-reference. So in theory after 1.0 you could fork mapnik-reference, add the missing definition yourself and use that for CartoCSS processing if necessary.

matthijsmelissen commented 6 years ago

No, in that case fixing it in mapnik-reference is clearly the way to go. Does cartocss recognize it automatically if it is added in mapbik-reference? In that case, the issue can be close sed on this side.

nebulon42 commented 6 years ago

Unfortunately, no. After adding it to mapnik-reference that needs a new release and a new package on npm. Then I have to bump the version number here and release CartoCSS and update the package on npm. While I have the rights to do all of this I still will open a PR on mapnik-reference so that others have the chance to comment.

matthijsmelissen commented 6 years ago

Clear, thanks!

nebulon42 commented 6 years ago

Small correction. Releasing and publishing mapnik-reference is sufficient. Since it is referenced by ~ in package.json new installs of CartoCSS would pick up the change automatically.

nebulon42 commented 6 years ago

PR pending.

matthijsmelissen commented 6 years ago

Do you have an issue number?

skorasaurus commented 6 years ago

https://github.com/mapnik/mapnik-reference/pull/145 @matthijsmelissen

nebulon42 commented 6 years ago

Closing here per https://github.com/mapbox/carto/issues/487#issuecomment-365047559.