Skip to content

encodePng beta ​

Function of @v12-engine/client

ts
export declare function encodePng(picture: MapPixels, deflate?: (data: Uint8Array) => Uint8Array): Uint8Array;

A picture as a PNG file. deflate makes the zlib stream of its rows: stored blocks of our own when left out, or a compressing one where there is one (zlib.deflateSync in Node), for a smaller file