mirror of
https://github.com/ddidderr/wuffs.git
synced 2026-11-17 16:32:11 +01:00
This moves from a 2-valued "basic (box) or fancy (triangle)" upsampling parameter to a 3-valued one, which can now represent the fact that libjpeg's and libwebp's fancy (triangle) upsampling is ever-so-slightly different (see script/script/replicate-libwebp-chroma-upsampling.go and its comments). This is not an optimization or pessimization per se, but for the record, the performance impact is mixed. name old speed new speed delta wuffs_jpeg_decode_19k_8bpp/clang14 317MB/s ± 0% 314MB/s ± 0% -0.99% (p=0.008 n=5+5) wuffs_jpeg_decode_30k_24bpp_progressive/clang14 318MB/s ± 0% 328MB/s ± 0% +3.13% (p=0.008 n=5+5) wuffs_jpeg_decode_30k_24bpp_sequential/clang14 879MB/s ± 0% 871MB/s ± 0% -0.83% (p=0.008 n=5+5) wuffs_jpeg_decode_77k_24bpp/clang14 719MB/s ± 0% 713MB/s ± 0% -0.89% (p=0.008 n=5+5) wuffs_jpeg_decode_552k_24bpp_420/clang14 779MB/s ± 0% 771MB/s ± 0% -1.01% (p=0.008 n=5+5) wuffs_jpeg_decode_552k_24bpp_444/clang14 902MB/s ± 0% 890MB/s ± 0% -1.32% (p=0.008 n=5+5) wuffs_jpeg_decode_4002k_24bpp/clang14 784MB/s ± 0% 779MB/s ± 0% -0.66% (p=0.008 n=5+5) wuffs_jpeg_decode_19k_8bpp/gcc12 358MB/s ± 0% 362MB/s ± 0% +0.93% (p=0.008 n=5+5) wuffs_jpeg_decode_30k_24bpp_progressive/gcc12 305MB/s ± 0% 311MB/s ± 0% +1.91% (p=0.008 n=5+5) wuffs_jpeg_decode_30k_24bpp_sequential/gcc12 912MB/s ± 0% 918MB/s ± 0% +0.73% (p=0.016 n=4+5) wuffs_jpeg_decode_77k_24bpp/gcc12 749MB/s ± 0% 763MB/s ± 0% +1.83% (p=0.008 n=5+5) wuffs_jpeg_decode_552k_24bpp_420/gcc12 813MB/s ± 0% 824MB/s ± 0% +1.37% (p=0.008 n=5+5) wuffs_jpeg_decode_552k_24bpp_444/gcc12 969MB/s ± 0% 984MB/s ± 0% +1.62% (p=0.008 n=5+5) wuffs_jpeg_decode_4002k_24bpp/gcc12 815MB/s ± 0% 832MB/s ± 0% +2.06% (p=0.008 n=5+5)
JPEG
JPEG (Joint Photographic Experts Group) is a lossy image compression format for opaque, still images.
The "Making Software - Image Compression" book chapter also has a good overview of a number of image formats, including JPEG.
Further Reading
Web pages:
- How JPEG works by Christopher G. Jennings.
- How JPG Works by Colt McAnlis.
- JPEG compression by Sophie Wang.
- JPEG Series, Part I: Visualizing the Inverse Discrete Cosine Transform by Alex Dowad.
- JPEG Series, Part II: Huffman Coding by Alex Dowad.
- Not so fast, Mr. Fourier! by Michał Zalewski.
- Understanding and Decoding a JPEG Image using Python by Yasoob Khalid.
- Unraveling the JPEG by Omar Shehata.
- Wikipedia's JPEG Encoding page.
YouTube videos:
- JPEG DCT, Discrete Cosine Transform (JPEG Pt2)- Computerphile.
- The Unreasonable Effectiveness of JPEG: A Signal Processing Approach.
Books:
You may be able to find these books at your local university's science library.
- Compressed Image File Formats: JPEG, PNG, GIF, XBM, BMP, also known as the white book.
- JPEG: Still Image Data Compression Standard, also known as the pink book.
Link collections: