Skip to content

Add JPEG/PNG conversion and reproducible heic-to benchmarks - #4

Merged
mhrsntrk merged 3 commits into
masterfrom
feat/conversion-benchmark
Sep 18, 2026
Merged

mhrsntrk merged 3 commits into
masterfrom
feat/conversion-benchmark

Conversation

@mhrsntrk

@mhrsntrk mhrsntrk commented Sep 18, 2026 •

Copy link
Copy Markdown
Contributor

HEIC callers can now convert the primary image directly to a JPEG or PNG Blob through convertHeic, with quality/resize/decode options and decode metadata. Conversion supports workers and releases its bitmap and canvas on success, encoder failure, and cancellation.

Raise the optional libheif-js peer minimum and development range to 1.23.2 (the lockfile already resolved that version). Release all libheif handles and the per-decode context, including error paths, to avoid accumulating contexts during repeated conversion.

Add a pinned heic-to 1.5.2 comparison harness and documentation. It separates fresh-context and warmed conversion, rotates sequential execution order, validates MIME/dimensions, reports actual decode strategies and raw samples, and serves photos only on loopback. CI smoke-tests the harness; private photos and generated reports remain ignored. Initial isolated Chromium measurements on two 9 MP tiled photos show warm medians of 361/471 ms versus 722/848 ms, both using our WASM fallback. These are limited local results, not hardware or universal speed claims.

Firefox 155 measurements on the same inputs show warm medians of 402/518 ms versus 894/1117 ms. Anonymous local reports contain raw samples, environment and source/build identity; no private photos or reports are committed. Each sample has a timeout, and the harness explicitly closes browser/server connections and its bundler service on exit.

Validation: typecheck, build, public package targets and consumer bundling, 80 unit tests, 38 Chromium/Firefox conversion and fallback tests (including two private photos), JPEG/PNG benchmark smoke tests, clean dependency audit. Shared CI covers all three browser engines. Includes a minor changeset for 0.2.0.

@mhrsntrk
mhrsntrk merged commit f71e02e into master Sep 18, 2026
2 checks passed
@mhrsntrk
mhrsntrk deleted the feat/conversion-benchmark branch September 18, 2026 21:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant