s2maps-gpu
Version:
S2 Maps GPU - An open source, high-performance, and GPU-accelerated map engine for rendering large-scale, interactive maps.
21 lines (20 loc) • 911 B
JavaScript
/** Earth's radius in meters */
export const EARTH_RADIUS = 6_371_008.8;
/** Earth's equitorial radius in meters */
export const EARTH_RADIUS_EQUATORIAL = 6_378_137;
/** Earth's polar radius in meters */
export const EARTH_RADIUS_POLAR = 6_356_752.3;
/** The average circumference of Earth in meters. */
export const EARTH_CIRCUMFERENCE = 40_030_228.88407185; // 2.0 * Math.PI * EARTH_RADIUS;
/**
* Returns the altitude of the lowest known point on Earth in meters. The lowest known
* point on Earth is the Challenger Deep with an altitude of 10898 meters
* below the surface of the spherical earth.
*/
export const EARTH_LOWEST_ALTITUDE = -10_898.0;
/**
* Returns the altitude of the highest known point on Earth in meters. The highest
* known point on Earth is Mount Everest with an altitude of 8846 meters
* above the surface of the spherical earth.
*/
export const EARTH_HIGHEST_ALTITUDE = 8_846.0;