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

CustomLayer with globe projection seems wrong #12584

Open
huanglii opened this issue Feb 22, 2023 · 4 comments
Open

CustomLayer with globe projection seems wrong #12584

huanglii opened this issue Feb 22, 2023 · 4 comments

Comments

@huanglii
Copy link

mapbox-gl-js version: 2.13.0

browser:

Steps to Trigger Behavior

  1. In the example of Add a custom style layer, change the projection to globe

Link to Demonstration

https://codesandbox.io/s/custom-layer-globe-v4iv2p?file=/index.html

Expected Behavior

image

Actual Behavior

image

@saschahofmann
Copy link

The docs seem pretty clear about this: Only the mercator projection is supported for custom layers. What I am wondering is whether there are plans to change that and what we could do to support that effort?

@sakitam-fdd
Copy link

This seems to be solved by rendering to RTT, but there are certain limitations. I have a toy here, please check it out https://codepen.io/sakitam-fdd/full/jOdgGve

image

@saschahofmann
Copy link

Do I understand this right that you had to define the projection yourself?

@sakitam-fdd
Copy link

I don't think it's entirely true. This only benefits the rendering process of ImageSource _setupProxiedCoordsForImageSource, treating the custom layer as a raster layer, so it has significant limitations

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
4 participants