What would it take to render Polar Stereographic projection imagery draped on the ground at the poles? Any chance this is supported by a cesium API (with accurate rendering relative to the ground) or would it require a custom webgl/shader implementation (and is that even possible in cesium without forking?)
Our use case involves displaying ground and overlay imagery at the poles, and the distortions involved in projecting equirectilinear projections (Geographic/WebMercator) to a sphere would distort the imagery to an unacceptable level, especially near the poles. This might not be noticeable when the imagery is just blue water or white snow, but actual imagery at the poles is distorted.
Here is an illustration of wind speed tiles being rendered to cesium:
You’ll notice that the tiles are getting compressed horizontally as they near the pole. This means that imagery near the pole is distorted.
And if you zoom in, you can really see the distortion:
These are supposed to be arrows.
(Not to mention that the page is furiously downloading 50 million tiles as view covers the eye of the pole.)
There is literally no way to avoid these issues if an equirectangular projection is used (Geographic/WebMercator). The only option is to use a different projection with a different tiling scheme (or single image).
We’re looking at EPSG:3995 for the north pole and EPSG:3031 for the south. We plan on making WMS requests for imagery in those projections. Here is a sample image request.
Solutions?
It’s fine if the answer is “it’s not possible”, but I’m mostly wondering about what it would take to make it possible.
Here are my findings so far:
- Custom projections in general would be “quite complicated, and have significant performance implications” (Kevin Ring, in a comment on Custom projections) but perhaps polar projections could be a special case.
- PR 6393 “Materials on Ground Primitives” didn’t seem to implement geographically accurate rendering.
- The Rectangle sandcastle renders a skewed rectangle so it can’t be used to render geographically accurate imagery.
- In post 7548 “north and south pole mapping”, Omar is surprised that distortion still happens even with geographic imagery (epsg:4326), but distortion is inevitable, especially as you near the pole (the distortion increases exponentially).
- In post 1366 “Recommendations on drawing a square over the poles?”, Hannah suggests using a polygon with a texture material, but 1) will that be geographically accurate, or will it only skew based on the polygon corners or bbox? and 2) will it clamp to ground?
- In post 6451 “Having trouble implementing Polar Stereographic Projection for Imagery Provider”, Gabby points towards some source code functions like ImageryLayer _reprojectTexture, but that appears to coerce the image to either Geographic or WebMercator, and representing the image in those equirectangular projection would introduce the distortion that we’re trying to avoid.
In general, it seems like in Cesium, all the imagery wants to be relative to an equirectangular CRS where “up” is north and “right” is east. So would this feature require custom webgl code? Performance issues were cited, but (speaking naively) couldn’t it be implemented in a way similar threejs decals? And I know Google Earth implemented special imagery cases for their polar caps, so it’s possible. I’m just wondering what the next step is.
Thanks