/** * Minimal, pure-JS PNG encoder — no compression, no dependencies. * * Used as a deterministic fallback when no browser canvas (`OffscreenCanvas`, * `convertToBlob`) is available — typically the Node-side vitest environment * for the BrowserQuiltRenderer determinism tests, plus headless / SSR paths * where Three.js can't render. * * Encodes RGBA8 pixels as a single PNG with one uncompressed DEFLATE block * inside the IDAT chunk. Spec-compliant per RFC 1950 + RFC 1951 + ISO PNG. * * @see W.067a: Content hashes must be stable cross-platform — pure JS encode * with no library dependency means the same input bytes produce the same * PNG bytes on every runtime, which is what the BrowserQuiltRenderer * determinism test asserts via SHA-256. * * NOT a general-purpose PNG library. Output is uncompressed (~4x larger than * a real encoder). Browser bundle: ~2KB. Use `OffscreenCanvas.convertToBlob` * in production browser paths for compression. */ /** * Encode RGBA8 pixels as a deterministic PNG byte stream. No compression * (uses stored DEFLATE blocks) so the output bytes are 100% deterministic * across runtimes. Suitable for snapshot tests and content-addressed * hashing of QuiltRenderer output. * * @param rgba Row-major RGBA bytes, length = width * height * 4 * @param width Image width in pixels * @param height Image height in pixels */ export declare function encodePngRgba(rgba: Uint8Array, width: number, height: number): Uint8Array; //# sourceMappingURL=pngEncoder.d.ts.map