-
Notifications
You must be signed in to change notification settings - Fork 2k
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
BitmapLayer supports globe projection #4655
Conversation
I still trying to wrap my mind around this. In the example, you're projecting this image onto the globe. That image is 4096x2048px, so it maps linearly to degrees of latitude and longitude spanning the globe. If you just stretched that image vertically to be a square, that would be nearly equivalent to an OSM web mercator tile at zoom 0 (except that in web mercator the latitude extremes are 85 degrees). So it's not clear why it works to wrap the example image around the globe, but doesn't work to project an OSM web mercator image onto the globe, given that there's a linear combination relating the two. |
Stretching a non-linear y axis still yields non-linear. See https://en.wikipedia.org/wiki/Mercator_projection#/media/File:Mercator_with_Tissot's_Indicatrices_of_Distortion.svg |
eba82f8
to
2fdfaa2
Compare
2fdfaa2
to
0a4836a
Compare
0a4836a
to
707e2c8
Compare
I understand that there will be warping no matter what when you're projecting a rectangular image onto an ellipsoid, but I don't understand why this would apply differently to the image used in the example compared to an image in web mercator. |
For #4638
Note that this implementation assumes that the world coordinates can be linearly interpolated along the pixels. This is not true with e.g. OSM raster tiles, which have been preprojected to the Web Mercator space. Ultimately, the issue is that the layer does not ask the user for sufficient information regarding the image. We will need to introduce additional APIs for a more generalized solution.
Change List
resolution
option toGlobeView