webMercatorMaxLatitude.glsl 757 B

12345678910111213141516
  1. /**
  2. * The maximum latitude, in radians, both North and South, supported by a Web Mercator
  3. * (EPSG:3857) projection. Technically, the Mercator projection is defined
  4. * for any latitude up to (but not including) 90 degrees, but it makes sense
  5. * to cut it off sooner because it grows exponentially with increasing latitude.
  6. * The logic behind this particular cutoff value, which is the one used by
  7. * Google Maps, Bing Maps, and Esri, is that it makes the projection
  8. * square. That is, the rectangle is equal in the X and Y directions.
  9. *
  10. * The constant value is computed as follows:
  11. * czm_pi * 0.5 - (2.0 * atan(exp(-czm_pi)))
  12. *
  13. * @name czm_webMercatorMaxLatitude
  14. * @glslConstant
  15. */
  16. const float czm_webMercatorMaxLatitude = 1.4844222297453324;