nodetiles / nodetiles-core

Render Leaflet compatible map tiles and UTFGrids using node-canvas on Heroku
BSD 3-Clause "New" or "Revised" License
47 stars 22 forks source link

Line Simplification #52

Open Mr0grog opened 11 years ago

Mr0grog commented 11 years ago

Ran across this library the other day: https://github.com/mourner/simplify-js

Could potentially use it to add line simplification as a feature. Not sure how valuable it would be (or the right way to expose it to use).

bensheldon commented 11 years ago

That would be awesome if we could get it into the data source side. We need to do more profiling, but sadly I think our bottlenecks are in the data connectors rather than our renderer.

On Sun, May 12, 2013 at 10:03 PM, Rob Brackett notifications@github.com wrote:

Ran across this library the other day: https://github.com/mourner/simplify-js

Could potentially use it to add line simplification as a feature. Not sure how valuable it would be (or the right way to expose it to use).

Reply to this email directly or view it on GitHub: https://github.com/codeforamerica/nodetiles-core/issues/52

Mr0grog commented 11 years ago

Oh, there's definitely bottlenecks in both ;)

FWIW, the biggest time-sink at the moment is, surprisingly, turning colors (from Carto's AST) into strings! That one is definitely renderer-side. There's also a huge amount of Array.forEach() use in the renderer, which is known to be slow (both for JS/C++ re-entry and for call frame creation). Don't remember off the top of my head what the other standout issues were when I was experimenting with node --prof (which is not friendly) about a month ago.

Mr0grog commented 11 years ago

That would be awesome if we could get it into the data source side

Also not really sure whether it would belong on the source side or whether the options should be specified via the style sheet (which seems to be a more natural fit, though harder technically to make work).