import { UsedRgbChannel } from '../utils'; export declare const WeatherVariableID: { GFS_TEMPERATURE_2M: string; GFS_PRESSURE_MSL: string; GFS_PRECIPITATION_1H: string; GFS_FROZEN_PRECIPITATION_PERCENT: string; GFS_WIND_10M: string; GFS_RADAR_COMPOSITE: string; GFS_CLOUD_COVER_TOTAL: string; }; export type WeatherVariableIDValue = (typeof WeatherVariableID)[keyof typeof WeatherVariableID]; /** * Extent of the area being covered. Usually in the unit if the CRS. */ export type Bounds = [number, number, number, number]; /** * Tileset matrix details for a specific zoom level */ export type MatrixSetItem = { /** * Specific zoom level of a given tileset */ zoom_level: number; /** * Dimensions of the matrix in tiles along the horizontal axis */ matrix_width: number; /** * Dimensions of the matrix in tiles along the vertical axis */ matrix_height: number; /** * Number of tiles along the horizontal axis */ tile_width: number; /** * Number of tiles along the vertical axis */ tile_height: number; /** * Number of pixel of each tile along the vertical axis */ pixel_x_size: number; /** * Number of pixel of each tile along the horizontal axis */ pixel_y_size: number; }; /** * Collection of tile matrix details per zoom level */ export type TileMatrixSet = { /** * Geographic exten of the tileset in the unit of projection (Mercator) */ bounds: Bounds; /** * Matrix details per zoom level */ items: Array; }; export type SpatialReferenceSystem = { /** * Name of the defining authority, eg. `"EPSG"` */ auth_name: string; /** * ID given by the defining authority, eg. `"3587"` */ auth_srid: string; /** * "Well Known Text" to describe the current spatial reference system (aka. CRS) */ wkt: string; }; export type Keyframe = { /** * Tileset id. Also used to form the URL of it */ id: string; /** * Timestamp as ISO8601 date format */ timestamp: string; }; /** * Details about a specific weather variable */ export type WeatherVariable = { /** * Version of the specification */ "@version": string; /** * Geographical extent of the tileset representing the bounds (in Mercator units) */ bounds: Bounds; /** * Type of tileset */ type: "mtpkg" | "virtual" | "mbtiles" | "geopackage"; /** * The type of tile */ tile_type: "raster" | "raster-dem" | "vector" | "terrain"; /** * Description of the tile matrix at each zoom level */ tile_matrix_set: TileMatrixSet; /** * Encoding type of each individual tile */ tile_format: "jpeg" | "png" | "webp" | "pbf" | "quantized-mesh-1.0"; /** * Description of the tileset's spatial reference system (aka. CRS) */ spatial_ref_sys: SpatialReferenceSystem; metadata: { /** * Format of the tile */ format: "jpeg" | "png" | "webp" | "pbf" | "quantized-mesh-1.0"; /** * TODO */ scheme: string; /** * TODO */ title: string; /** * Bounds in WGS84 */ bounds: Bounds; /** * Center of the bounds */ center: Array; /** * Minimal zoom level this tileset contains. Cannot be lower than 0, but could be higher */ minzoom: number; /** * Maximal zool level this tileset contains. Cannot be higher than 22, but mostl likely lower */ maxzoom: number; /** * Factor of `256` reprensting the size of raster tiles. (`1` means tiles are 256x256px, `2` means 512x512px) * The scale is received as a string. */ scale?: number; /** * Description of the weather variable */ weather_variable: { /** * Human friendly name of the weather variable (eg. "Temperature") */ name: string; /** * Human friendly description of this weather variable */ description: string; /** * Attribution to credit the source for this weather data */ attribution: string; /** * Identifier of this weather variable */ variable_id: WeatherVariableIDValue; /** * Information to decode the values of this specific weather variable */ decoding: { /** * The minimum value in real world unit. This is mapped to the 0 in the uint8 range. */ min: number; /** * The minimum value in real world unit. This is mapped to the 255 in the uint8 range. */ max: number; /** * Channel or combination of image channels that is/are used to encode this weather variable within each tile's pixel. */ channels: UsedRgbChannel; }; /** * Real world unit used for this variable */ unit: string; /** * Release data of the dataset. * Date in ISO8601 format. */ release_timestamp: string; /** * */ timestamp: string; }; }; /** * Tileset per time tick */ keyframes: Array; }; export type WeatherPayload = { variables: Array; };