UNPKG

arso-rainfall-intensity

Version:

!!!Only for slovenia!!! Provides simple api for fetching radar images of rainfall intensity and parsing from pixels and converting pixel coordinates to pairs of latitude and longitude or vice versa.

26 lines 1.17 kB
/// <reference types="node" /> import { InterfaceProjection } from 'proj4'; import { PNG } from "pngjs"; import { IPoint, IPixel } from './types'; export default class RadarImageProjection { protected degreeP: InterfaceProjection; protected meterP: InterfaceProjection; protected mBoundSW: IPoint; protected mBoundNE: IPoint; protected dBoundSW: IPoint; protected dBoundNE: IPoint; protected image: PNG | null; constructor(degreeUnitProjectionName: string, meterUnitProjectionName: string, degBboxSW: IPoint, degBboxNE: IPoint); get width(): number; get height(): number; loadImageFromBuffer(buffer: Buffer): void; getImageBuffer(): Buffer; getPixelInfo({ x, y }: IPoint): IPixel; projectImagePixelToDegreeUnit({ x, y }: IPoint): IPoint; projectImagePixelToMeterUnit({ x, y }: IPoint): IPoint; projectDegreeUnitToImagePixel({ x, y }: IPoint): IPoint; projectMeterUnitToImagePixel({ x, y }: IPoint): IPoint; projectDegrees2MeterUnits({ x, y }: IPoint): IPoint; projectMetersToDegreeUnits({ x, y }: IPoint): IPoint; } //# sourceMappingURL=radar-image-projection.d.ts.map