gis-tools-ts
Version:
A collection of geospatial tools primarily designed for WGS84, Web Mercator, and S2.
24 lines • 1.04 kB
TypeScript
import type { MValue, Properties, VectorFeature } from '../../index.js';
/**
* Reproject GeoJSON geometry coordinates from lon-lat to a 0->1 coordinate system in place
* @param feature - input GeoJSON
*/
export declare function toUnitScale<M = Record<string, unknown>, D extends MValue = Properties, P extends Properties = Properties>(feature: VectorFeature<M, D, P>): void;
/**
* Reproject GeoJSON vector geometry coordinates from 0->1 coordinate system to lon-lat in place
* @param feature - input GeoJSON
*/
export declare function toLL<M = Record<string, unknown>, D extends MValue = Properties, P extends Properties = Properties>(feature: VectorFeature<M, D, P>): void;
/**
* Convert a longitude to a 0->1 coordinate
* @param x - longitude
* @returns a 0->1 coordinate
*/
export declare function projectX(x: number): number;
/**
* Convert a latitude to a 0->1 coordinate
* @param y - latitude
* @returns a 0->1 coordinate
*/
export declare function projectY(y: number): number;
//# sourceMappingURL=unitScale.d.ts.map