UNPKG

s2maps-gpu

Version:

S2 Maps GPU - An open source, high-performance, and GPU-accelerated map engine for rendering large-scale, interactive maps.

25 lines (24 loc) 1.13 kB
import type { VectorPoint } from 'gis-tools/index.js'; /** * Get the longitude and latitude of the cursor position in the S2 Geometry Projection. * centerLon and centerlat is where the center of the sphere is currently located * x is the distance from center * @param centerLon - center longitude * @param centerLat - center latitude * @param xOffset - distance from center * @param yOffset - distance from center * @param radius - the radius of the sphere * @returns longitude and latitude */ export declare function cursorToLonLatS2(centerLon: number, centerLat: number, xOffset: number, yOffset: number, radius: number): undefined | VectorPoint; /** * Get the longitude and latitude of the cursor position in the web mercator projection. * @param lon - center longitude * @param lat - center latitude * @param xOffset - x offset * @param yOffset - y offset * @param zoom - zoom * @param tileSize - tile size * @returns longitude and latitude */ export declare function cursorToLonLatWM(lon: number, lat: number, xOffset: number, yOffset: number, zoom: number, tileSize: number): undefined | VectorPoint;