the writer to append to
the tile type
the compression algorithm to use for internal data like the header, directories, and metadata
Readonly
internalthe compression algorithm to use for internal data like the header, directories, and metadata
Readonly
typethe tile type
Readonly
writerthe writer to append to
Finish writing by building the header with root and leaf directories
the metadata to store
the compression algorithm that was used on the tiles [Default: None]
Write a tile to the PMTiles file given its tile ID.
the tile ID
the tile data
Optional
face: FaceIf it exists, then we are storing S2 data
Write a tile to the PMTiles file given its (face, zoom, x, y) coordinates.
the Open S2 projection face
the zoom level
the tile X coordinate
the tile Y coordinate
the tile data to store
Write a tile to the PMTiles file given its (z, x, y) coordinates.
the zoom level
the tile X coordinate
the tile Y coordinate
the tile data to store
S2 PMTiles Writer
About
Writes data via the S2-PMTiles specification.
A Modified TypeScript implementation of the PMTiles library. It is backwards compatible but offers support for the S2 Projection.
Usage
Browser Compatible
Node/Deno/Bun using the filesystem
Links