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

In-browser polygon tesselation #935

Closed
wants to merge 30 commits into from
Closed

In-browser polygon tesselation #935

wants to merge 30 commits into from

Conversation

mourner
Copy link
Member

@mourner mourner commented Jan 14, 2015

Closes #682. Not ready yet. To do:

  • implement holed polygon -> single ring polygon conversion algorithm as described in FIST paper
  • implement outer/inner rings classification
  • ditch libtess code completely
  • fix artifacts on some complex water polygons
  • solve low-zoom degenerate water polygons issue
  • make sure there are no glaring artifacts browsing through the map
  • fix tests
  • maybe make triangulation code a separate repo https://github.com/mapbox/earcut
  • fix fill antialiasing @ansis
  • fix fill patterns @ansis

@ljbade
Copy link

ljbade commented Jan 15, 2015

+1 for making a seperate lib/repo as people will be interested in a decent triangulation lib. Same for when it gets ported to C++

@mourner mourner force-pushed the earcut branch 2 times, most recently from df78343 to 0dccfa1 Compare January 20, 2015 09:57
@mourner
Copy link
Member Author

mourner commented Jan 20, 2015

@ansis 2 more problems with tesselated fill rendering: anti-aliasing is broken (polygon edges look crappy if you look closely), and fill-pattern is broken.

Introduce a StyleLayer class for the in-memory representation
of a style layer.

It handles constant resolution, paint property cascading, and
paint property calculation. The paint functions now accept a
layer as one of the parameters and read all layer properties from
it. This simplifies the rendering flow quite a bit.

The concept of a "bucket" is now something that only the workers
need to know about. The main thread does not create buckets, it
merely stores the buffers and elementGroups on the tile when they
are received from the worker.
_cascade ⇢ _resolve (called automatically)
_cascadeClasses ⇢ _cascade (called when classes change)
recalculate ⇢ _recalculate (it's internal-only)
This is a blend of #901 and #939.

The format for featuresAt results changed again. Instead of
result-per-geometry-cross-layer, each result has a `layers`
array with all layers that contain the feature. Thus avoiding
duplication of geometry and properties in the result set.
This can happen if the referent layer is skipped due to min/maxzoom.
@mourner
Copy link
Member Author

mourner commented Jan 22, 2015

Need to target another branch so closing. -> #948

@mourner mourner closed this Jan 22, 2015
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

Successfully merging this pull request may close these issues.

5 participants