Skip to content

Latest commit

 

History

History
23 lines (11 loc) · 1.34 KB

README.md

File metadata and controls

23 lines (11 loc) · 1.34 KB

JPEG Sandbox

This is a very barebones editor that supports clicking on any pixel in a JPEG image to see the 64 DCT coefficients that make up that 8x8 block. Each individual coefficient can be edited through text. You can also use the slider to zero out coefficients one by one starting with the lowest absolute value (which is what you'd do during compression) or reverse that to see what it would look like to throw away the most important coefficients first.

jpeg-sandbox

It also visualizes the coefficients that make up each individual block in order of their weight.

jpeg-sandbox2

I created this to help with explaining how JPEG works for a talk at CodeBar 2022.

Cat picture by Mikhail Vasilyev. Also inspired by the visualization in https://www.jezzamon.com/fourier/.

See also my Unraveling the JPEG article.

Local setup

Run yarn to install dependencies and yarn dev to run. Run the app on localhost:3000.