ae_albert-einshutoin~/portfolio

lazy-imageTRY IT

Explore image size, quality, and processing time.
Compare lazy-image and other Wasm libraries using the same image.

01 / SIZE POLICY

Search for quality that meets a size target

Search from quality 45 to your chosen upper bound. Strict mode returns an error if the target is missed, without producing output.

02 / PRIVATE BY DESIGN

Process images without sending them elsewhere

Re-encode locally with metadata retention disabled. Images are not sent to external services.

03 / PREPARE ONCE

Load and resize once

Encode the same pixels at different quality levels. Inspect processing time and estimated pixel buffer size.

Input and output protections in this demo
  • JPEG, PNG, and WebP inputs up to 5 MiB / 16 MP. Header dimensions are checked before decoding.
  • Each Worker runs for at most 30 seconds. Cancelling or navigating away terminates it.
  • Output format, dimensions, size target, and native browser decoding are checked before display.

Pixel limits do not guarantee a total memory limit. This demo uses Wasm version 1.4.3.Node.js sanitisation and verified image-set generationare separate APIs.

Image workspace GitHub
Image conversion settings

Choose an image or try the sample.

Target-size mode searches quality candidates from 45 to the chosen upper bound for each engine. Photon's WebP output is a single lossless encode without a quality setting and is excluded from this search comparison. Equal numeric quality settings do not guarantee equal visual quality.

30 seconds per job / 120 seconds for the measurement sequence

Loading Playground…

Measurements run one Worker at a time, without previews or retained prior outputs. Initialisation, conversion, and output validation are recorded separately, including the first run and repeats after one warm-up. Display-only reruns and RGB PSNR happen afterwards and are excluded from timing. The reference is jSquash decoding plus Lanczos3 at the same dimensions. PSNR measures white-background RGB error, not perceived or equal quality. Execution order, cache, device load, and small sample sizes still affect the results.

View memory measurements from an isolated environment

Each Node/Wasm trial runs in its own process and records the OS peak RSS. This measures the whole process, including initialisation, input, and Node—not this browser or Cloudflare Workers. GPU memory and quality analysis after RSS collection are excluded.

EXPLORER

Vim controls, too

You can also click or tap.

j / k
Scroll down / up
h / l
Previous / next tab
gt / gT
Next / previous tab
2gt / 3gt
Second / third tab from the left
2gT / 3gT
Go back 2 / 3 tabs
Ctrl+d / Ctrl+u
Scroll half a page down / up
gg / G
Top / bottom of page
: / /
Command / search
n / N
Next / previous match
? / Esc
Help / close or clear search

:projects、:playground、:about to open a page.
:tabnext / :tabprevious for next / previous,:tabfirst / :tablast for first / last tab.:tabclose to close the current tab.

Close tabs with × or Delete. Shortcuts do not run while typing.