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

Outer rings sometimes dropped #87

Open
nvkelso opened this issue Jan 12, 2017 · 2 comments
Open

Outer rings sometimes dropped #87

nvkelso opened this issue Jan 12, 2017 · 2 comments

Comments

@nvkelso
Copy link
Member

nvkelso commented Jan 12, 2017

Outside of Bremen, Germany some of the larger meadow landuse polygons are broken / missing large pieces in MVT compared to the same tile in TopoJSON. (I vaguely remember the same thing happening to some of the plodder "wetland/ farmland" landuse outside of Amsterdam, too?)

To replicate this problem "Open" the following GIST into Tangram Play:
https://api.github.com/gists/35bc3a9b8adb925dd7e4e8c64f60c506

And zoom the map to (update the address bar URL):
10.8042/53.1278/8.6035

Changing the source from MVT:

    osm:
        type: MVT
        url: https://tile.mapzen.com/mapzen/vector/v1/all/{z}/{x}/{y}.mvt

to GeoJSON:

    osm:
        type: GeoJSON
        url: https://tile.mapzen.com/mapzen/vector/v1/all/{z}/{x}/{y}.json

Shows the raw output of tile build is okay, but the later transformation encoding the features to MVT is borked.

Bad MVT encoding:

screen shot 2017-01-12 at 11 49 41

Good source GeoJSON tiles:

screen shot 2017-01-12 at 11 49 33

/cc @hjanetzek

@zerebubuth
Copy link
Member

It's not just some of the larger meadow polygons - many smaller polygons of meadow and the two other kinds of green (forest and wood?) are missing too. The image below shows the difference between the two images:

image

😖

@adodo1
Copy link

adodo1 commented Dec 21, 2017

see my issues #103

because the polygon part

to solve like this

for example:

a polygon in geojson >>

{
    "type": "Feature",
    "geometry": {
        "type": "Polygon",
        "coordinates": [
            [
                [0, 0],
                [10, 0],
                [0, 10],
                [0, 0]
            ],
            [
                [15, 0],
                [15, 15],
                [30, 0],
                [15, 0]
            ]
        ]
    }
}

you must make it to MultiPolygon like this

{
    "type": "Feature",
    "geometry": {
        "type": "MultiPolygon",
        "coordinates": [
            [[
                [0, 0],
                [10, 0],
                [0, 10],
                [0, 0]
            ]],
            [[
                [15, 0],
                [15, 15],
                [30, 0],
                [15, 0]
            ]]
        ]
    }
}

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

3 participants