uber / nebula.gl

A suite of 3D-enabled data editing overlays, suitable for deck.gl
https://nebula.gl/
Other
689 stars 165 forks source link

Translating Features of large distances heavily distorts & flips them (at ~+-90°long) #898

Open mmodrow opened 6 months ago

mmodrow commented 6 months ago

Describe the bug

When I create any feature (e.g. go to the geojson-editor demo and load blank, afterwards draw a polygon) and then translate it more than 90° along long in any direction, the feature gets totally destroyed along the closest pole and when translated further along the long axis, it returns to normal, but upside down.

Actual Result

Widely distorted translated feature, that has no resemblance of the original feature, even though the default projection should not distort on long-translation at moderate lat coords. E.g. outlining the USA and translating them to Europe gives random shapes at Arctica.

Expected Result

Translating the outline of the USA to Europe should put the outline of the USA undistored ontop of the EU

Reproduce Steps

Screenshots

nebula_feature_translate_distortion

To Do List

ibgreen commented 6 months ago

A native attempt to break this down into smaller more actionable issues:

igorDykhta commented 6 months ago

@mmodrow Have you tried screenSpace prop?

mmodrow commented 6 months ago

Could you please elaborate, @igorDykhta ? I find no such prop anywhere in the code or documentation of nebula, deck or mapbox... Where would I set this?

igorDykhta commented 6 months ago

@mmodrow

Translate mode

Not exactly sure how good it works near the poles.

mmodrow commented 6 months ago

Apparently I already had it on screenSpace: true. unsetting it made no difference...